Commit Graph

13802 Commits

Author SHA1 Message Date
Jamie Nicol
e0d0ac8af5 Bug 1610952 - Ensure webrender's async scroll offsets are in correct coordinate space. r=botond
For zoomable APZCs, we were correctly dividing the scroll offset by
the pinch zoom scale. This is effectively equal to multiplying by the
device pixel ratio then dividing by the zoom, converting the offset
from parent layer space to layout device space.

However, for non-zoomable APZCs, we were incorrectly assuming that the
pinch zoom scale equalled 1.0. This was causing us to send incorrectly
scaled async scroll offsets to webrender, resulting in content moving
too slowly or quickly whilst asynchronously panning, then suddenly
jumping as the synchronous scroll offset caught up.

This is fixed by ensuring we always divide the asynchronous scroll
offset by the pinch zoom scale, regardless of whether the APZC is
zoomable or not.

Differential Revision: https://phabricator.services.mozilla.com/D61315

--HG--
extra : moz-landing-system : lando
2020-01-31 08:52:11 +00:00
Dorel Luca
983a71b2a4 Backed out changeset 9dc9deb3ba3b (bug 1611660) for Reftest failure in layout/reftests/bugs/605138-1.html == layout/reftests/bugs/605138-1-ref.html 2020-01-31 01:44:08 +02:00
Kousuke Takaki
04bba6950f Bug 1602088 - Move nsIScrollableFrame::ScrollUnit to namespace scope. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D61140

--HG--
extra : source : 69fded25adc2ac25e302b49c1128f8926e1311a3
2020-01-30 09:13:19 +00:00
Cosmin Sabou
5a3d320cd0 Backed out changeset 69fded25adc2 (bug 1602088) for causing several box-shadow reftest failures.
CLOSED TREE
2020-01-30 13:23:10 +02:00
Greg V
2befd54d63 Bug 1484812 - Use SwapBuffersWithDamage on EGL platforms (Wayland/Android) r=jnicol,mstange,jgilbert
EGL_KHR_swap_buffers_with_damage (or EGL_EXT_swap_buffers_with_damage)
is an EGL extension that allows the application to inform the display
server (system compositor) which areas of the window have changed.

This commit implements support for that extension in the layers compositor.
The layers compositor always renders the whole frame, so we're only getting
the benefit of not redrawing unchanged areas *in the system compositor*,
not actually doing partial invalidation/compositing,
but that makes the implementation simpler (no need to track buffer age).

Differential Revision: https://phabricator.services.mozilla.com/D51517

--HG--
extra : moz-landing-system : lando
2020-01-30 10:46:54 +00:00
Botond Ballo
f62b4f716b Bug 1611660 - Accept layout viewport updates from the main thread right away. r=tnikkel
Previously, we would wait until the following frame (for uncertain reasons
that date back to B2G), but this meant the layout and visual viewports would
be out of sync for a frame, causing APZ to misbehave.

Differential Revision: https://phabricator.services.mozilla.com/D61286

--HG--
extra : moz-landing-system : lando
2020-01-30 10:48:34 +00:00
Kousuke Takaki
9681569b70 Bug 1602088 - Move nsIScrollableFrame::ScrollUnit to namespace scope. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D61140

--HG--
extra : moz-landing-system : lando
2020-01-30 09:13:19 +00:00
sotaro
9fbc3e628e Bug 1605777 - Clear WrappingTextureSourceYCbCrBasic::mTexture correctly r=nical
Differential Revision: https://phabricator.services.mozilla.com/D60639

--HG--
extra : moz-landing-system : lando
2020-01-23 11:11:46 +00:00
Miko Mynttinen
fba2799f7a Bug 1558926 - Part 2: Use DisplayItemCache in WebRenderCommandBuilder
Differential Revision: https://phabricator.services.mozilla.com/D60756

--HG--
extra : moz-landing-system : lando
2020-01-27 14:18:17 +00:00
Miko Mynttinen
5c231763e7 Bug 1558926 - Part 1: Add data structures and pref for display item caching r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D50221

--HG--
extra : moz-landing-system : lando
2020-01-27 14:17:43 +00:00
Hiroyuki Ikezoe
677e8ea65a Bug 1594451 - Apply fixed margin offset for position sticky layers/nodes depending on where it's stuck to. r=botond
We currenly only support the dynamic toolbar at bottom, so we apply the
`fixed margin offset` only if the sticky element is stuck at the bottom
of the root scroll container.

Differential Revision: https://phabricator.services.mozilla.com/D60066

--HG--
extra : moz-landing-system : lando
2020-01-25 11:00:08 +00:00
Hiroyuki Ikezoe
5d9fe8f9ea Bug 1594451 - Propagate sticky position info to HitTestingNode. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D60065

--HG--
extra : moz-landing-system : lando
2020-01-25 10:25:16 +00:00
Botond Ballo
7ce6d46176 Bug 1611523 - Use the current layers id to simplify IsFixedToRootContent(). r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D61016

--HG--
extra : moz-landing-system : lando
2020-01-25 00:23:44 +00:00
Botond Ballo
a20a5d30fe Bug 1611523 - Track the current layers id during the layer tree traversal in AsyncCompositionManager::ApplyAsyncContentTransformToTree(). r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D61015

--HG--
extra : moz-landing-system : lando
2020-01-25 00:23:34 +00:00
Brindusan Cristian
5ca7181fab Backed out 5 changesets (bug 1558926) for WebRender build bustages. CLOSED TREE
Backed out changeset 974bcab6b1bf (bug 1558926)
Backed out changeset 1865e6d29dcf (bug 1558926)
Backed out changeset 92b415dac733 (bug 1558926)
Backed out changeset 30481c41873a (bug 1558926)
Backed out changeset a4d9a1af297a (bug 1558926)
2020-01-24 20:42:16 +02:00
Miko Mynttinen
7a53d2c64c Bug 1558926 - Part 2: Use DisplayItemCache in WebRenderCommandBuilder
Depends on D50221

Differential Revision: https://phabricator.services.mozilla.com/D60756

--HG--
extra : moz-landing-system : lando
2020-01-22 22:41:06 +00:00
Miko Mynttinen
e9f5497f95 Bug 1558926 - Part 1: Add data structures and pref for display item caching r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D50221

--HG--
extra : moz-landing-system : lando
2020-01-22 22:17:18 +00:00
sotaro
56b30bd8c4 Bug 1602643 - Disable WebRender compositor dinamically for async screenshot r=gw
Differential Revision: https://phabricator.services.mozilla.com/D59658

--HG--
extra : moz-landing-system : lando
2020-01-23 23:52:05 +00:00
Mihai Alexandru Michis
d8a8849254 Backed out changeset f3b490c076d6 (bug 1602643) for causing bustages regarding CompositorKindChanged
CLOSED TREE
2020-01-23 16:27:33 +02:00
sotaro
7afb826ef9 Bug 1602643 - Disable WebRender compositor dinamically for async screenshot r=gw
Differential Revision: https://phabricator.services.mozilla.com/D59658

--HG--
extra : moz-landing-system : lando
2020-01-23 04:37:28 +00:00
Bob Owen
78557e5083 Bug 1604800 Part 1: Add a new WRAP_AND_RECORD SurfaceType for SourceSurfaceWrapAndRecord. r=jrmuizel
This is to avoid type confusion with SourceSurfaceRecording.

Differential Revision: https://phabricator.services.mozilla.com/D60735

--HG--
extra : moz-landing-system : lando
2020-01-22 21:21:08 +00:00
Boris Chiou
98e40ec294 Bug 1592822 - Replace StyleVecU8 with ipc::ByteBuf. r=emilio
We generate ByteBuf by rust bindgen, so we can drop StyleVecU8.
One potential follow-up is that we can merge this together with WrVecU8.

Differential Revision: https://phabricator.services.mozilla.com/D60328

--HG--
rename : ipc/glue/ByteBuf.h => ipc/glue/ByteBufUtils.h
extra : moz-landing-system : lando
2020-01-22 20:18:40 +00:00
Boris Chiou
ffa1ebad7b Bug 1592822 - Use Serde for OffsetRotate and PositionOrAuto. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60088

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:38 +00:00
Boris Chiou
14387265a7 Bug 1592822 - Use Serde for SVGOffsetPath. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60087

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:35 +00:00
Boris Chiou
38cc52c091 Bug 1592822 - Use Serde for Transform. r=emilio
Though this may make us use more space when serializing
StyleTransform, but we don't have to do extra conversion on the compostior
side, and this makes us easier to maintain the Rust type.

Differential Revision: https://phabricator.services.mozilla.com/D60045

--HG--
extra : moz-landing-system : lando
2020-01-22 20:20:38 +00:00
Boris Chiou
7b90a66fcb Bug 1592822 - Use Serde for rotate, scale, and translate properties. r=emilio
The only drawback is: we resolve LengthPercentage value before passing
translate property through IPC, so its percentage part is redundant.
However, this makes us easier to maintain the Rust type.

Differential Revision: https://phabricator.services.mozilla.com/D60044

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:31 +00:00
Boris Chiou
f3dc7fa3c7 Bug 1592822 - Use macro for the implementation of ParamTraits<> on types which support Serde. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60610

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:24 +00:00
Bogdan Tara
958c34b738 Backed out 6 changesets (bug 1592822) for bustages complaining about layout/painting/nsDisplayList.cpp CLOSED TREE
Backed out changeset 90d0f2ebd310 (bug 1592822)
Backed out changeset 9890bad86a0e (bug 1592822)
Backed out changeset 43870cc90433 (bug 1592822)
Backed out changeset d80e0e3f5b87 (bug 1592822)
Backed out changeset 99be49183325 (bug 1592822)
Backed out changeset 9ce641556acc (bug 1592822)

--HG--
extra : histedit_source : fa4e4b2c899510f1d39ee3baa0374e2ce16d2815
2020-01-22 21:17:39 +02:00
Boris Chiou
4f3076794c Bug 1592822 - Replace StyleVecU8 with ipc::ByteBuf. r=emilio
We generate ByteBuf by rust bindgen, so we can drop StyleVecU8.
One potential follow-up is that we can merge this together with WrVecU8.

Differential Revision: https://phabricator.services.mozilla.com/D60328

--HG--
rename : ipc/glue/ByteBuf.h => ipc/glue/ByteBufUtils.h
extra : moz-landing-system : lando
2020-01-22 18:42:54 +00:00
Boris Chiou
e10013895e Bug 1592822 - Use Serde for OffsetRotate and PositionOrAuto. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60088

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:19 +00:00
Boris Chiou
40f3cb3d65 Bug 1592822 - Use Serde for SVGOffsetPath. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60087

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:11 +00:00
Boris Chiou
9735c2e972 Bug 1592822 - Use Serde for Transform. r=emilio
Though this may make us use more space when serializing
StyleTransform, but we don't have to do extra conversion on the compostior
side, and this makes us easier to maintain the Rust type.

Differential Revision: https://phabricator.services.mozilla.com/D60045

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:09 +00:00
Boris Chiou
73f0ae66a9 Bug 1592822 - Use Serde for rotate, scale, and translate properties. r=emilio
The only drawback is: we resolve LengthPercentage value before passing
translate property through IPC, so its percentage part is redundant.
However, this makes us easier to maintain the Rust type.

Differential Revision: https://phabricator.services.mozilla.com/D60044

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:07 +00:00
Boris Chiou
c3faeb70ea Bug 1592822 - Use macro for the implementation of ParamTraits<> on types which support Serde. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60610

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:05 +00:00
Aaron Klotz
9847ab1f71 Bug 1610878: Remove using namespace mozilla::java directive from AndroidAPZ.cpp; r=botond
Differential Revision: https://phabricator.services.mozilla.com/D60709

--HG--
extra : moz-landing-system : lando
2020-01-22 17:45:13 +00:00
Sylvestre Ledru
187e9bafaf Bug 1519636 - Automatically reformat recent changes using clang-format r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D60354

--HG--
extra : moz-landing-system : lando
2020-01-21 09:51:27 +00:00
Makoto Kato
a94e918a29 Bug 1574307 - Part 1. Parse viewport-fit in meta element. r=smaug
For safe area insets (cutout) support, CSS Round Display Level 1 (https://drafts.csswg.org/css-round-display/#viewport-fit-descriptor) has new viewport value as `viewport-fit`.

To support safe area insets that is notch on display, CSS Environment Variables Module Level 1 (https://drafts.csswg.org/css-env-1/#safe-area-insets) adds `safearea-insets-*` (left, top, right and bottom). Also, `meta` element has `viewport-fit` enum value. (ex `<meta name="viewport" content="viewport-fit=cover>`) whether web browser window cover notch area.

`viewport-fit` has 3 enum value, `auto`, `cover` and `contain`.  GeckoView wants to expose this value to browser application such Fenix. Because Android API (https://developer.android.com/guide/topics/display-cutout) uses window root layout (It is set by Application) to cover notch on display.

Differential Revision: https://phabricator.services.mozilla.com/D55609

--HG--
extra : moz-landing-system : lando
2020-01-20 08:40:05 +00:00
Eric Rahm
cfd1cc461f Bug 1610388 - Remove nsAutoPtr usage from gfx/. r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D60456

--HG--
extra : moz-landing-system : lando
2020-01-21 01:25:28 +00:00
Emilio Cobos Álvarez
256c124f94 Bug 1609996 - Reorder some includes affected by the previous patches. r=froydnj
This was done by:

This was done by applying:

```
diff --git a/python/mozbuild/mozbuild/code-analysis/mach_commands.py b/python/mozbuild/mozbuild/code-analysis/mach_commands.py
index 789affde7bbf..fe33c4c7d4d1 100644
--- a/python/mozbuild/mozbuild/code-analysis/mach_commands.py
+++ b/python/mozbuild/mozbuild/code-analysis/mach_commands.py
@@ -2007,7 +2007,7 @@ class StaticAnalysis(MachCommandBase):
         from subprocess import Popen, PIPE, check_output, CalledProcessError

         diff_process = Popen(self._get_clang_format_diff_command(commit), stdout=PIPE)
-        args = [sys.executable, clang_format_diff, "-p1", "-binary=%s" % clang_format]
+        args = [sys.executable, clang_format_diff, "-p1", "-binary=%s" % clang_format, '-sort-includes']

         if not output_file:
             args.append("-i")
```

Then running `./mach clang-format -c <commit-hash>`

Then undoing that patch.

Then running check_spidermonkey_style.py --fixup

Then running `./mach clang-format`

I had to fix four things:

 * I needed to move <utility> back down in GuardObjects.h because I was hitting
   obscure problems with our system include wrappers like this:

0:03.94 /usr/include/stdlib.h:550:14: error: exception specification in declaration does not match previous declaration
0:03.94 extern void *realloc (void *__ptr, size_t __size)
0:03.94              ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/malloc_decls.h:53:1: note: previous declaration is here
0:03.94 MALLOC_DECL(realloc, void*, void*, size_t)
0:03.94 ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/mozilla/mozalloc.h:22:32: note: expanded from macro 'MALLOC_DECL'
0:03.94     MOZ_MEMORY_API return_type name##_impl(__VA_ARGS__);
0:03.94                                ^
0:03.94 <scratch space>:178:1: note: expanded from here
0:03.94 realloc_impl
0:03.94 ^
0:03.94 /home/emilio/src/moz/gecko-2/obj-debug/dist/include/mozmemory_wrap.h:142:41: note: expanded from macro 'realloc_impl'
0:03.94 #define realloc_impl mozmem_malloc_impl(realloc)

   Which I really didn't feel like digging into.

 * I had to restore the order of TrustOverrideUtils.h and related files in nss
   because the .inc files depend on TrustOverrideUtils.h being included earlier.

 * I had to add a missing include to RollingNumber.h

 * Also had to partially restore include order in JsepSessionImpl.cpp to avoid
   some -WError issues due to some static inline functions being defined in a
   header but not used in the rest of the compilation unit.

Differential Revision: https://phabricator.services.mozilla.com/D60327

--HG--
extra : moz-landing-system : lando
2020-01-20 16:19:48 +00:00
Emilio Cobos Álvarez
aa3a695712 Bug 1609996 - Remove mozilla/Move.h. r=froydnj
rg -l 'mozilla/Move.h' | xargs sed -i 's/#include "mozilla\/Move.h"/#include <utility>/g'

Further manual fixups and cleanups to the include order incoming.

Differential Revision: https://phabricator.services.mozilla.com/D60323

--HG--
extra : moz-landing-system : lando
2020-01-20 16:18:20 +00:00
Emilio Cobos Álvarez
5cd5e6f148 Bug 1609996 - Remove mozilla::Swap in favor of std::swap. r=froydnj
Now mfbt/Move.h is empty except for that excellent comment about move
semantics... Should we put it somewhere else and delete the header as a
follow-up? Or just delete the header and carry on?

Differential Revision: https://phabricator.services.mozilla.com/D60297

--HG--
extra : moz-landing-system : lando
2020-01-20 16:17:06 +00:00
Jamie Nicol
8d2ae82a39 Bug 1609002 - Attach fixed-position elements to the layout viewport in webrender. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D60292

--HG--
extra : moz-landing-system : lando
2020-01-18 01:10:45 +00:00
Nazım Can Altınova
d8afe0647a Bug 1609708 - Rename PROFILER_TRACING to PROFILER_TRACING_MARKER. r=gerald
Depends on D60229

Differential Revision: https://phabricator.services.mozilla.com/D60231

--HG--
extra : moz-landing-system : lando
2020-01-17 21:29:15 +00:00
Sylvestre Ledru
cc2040bf21 Bug 1605934 - Use nested namespaces r=sg
Done with:
./mach static-analysis check --checks="-*, modernize-concat-nested-namespaces" --fix .
and then clang-format on the files

Differential Revision: https://phabricator.services.mozilla.com/D58217

--HG--
extra : moz-landing-system : lando
2020-01-18 13:48:34 +00:00
Dorel Luca
506e65bcab Backed out changeset bbb39655cf71 (bug 1605934) for build bustage in widget/gtk/mozwayland/mozwayland.c 2020-01-18 15:39:55 +02:00
Sylvestre Ledru
6689a37527 Bug 1605934 - Use nested namespaces r=sg
Done with:
./mach static-analysis check --checks="-*, modernize-concat-nested-namespaces" --fix .
and then clang-format on the files

Differential Revision: https://phabricator.services.mozilla.com/D58217

--HG--
extra : moz-landing-system : lando
2020-01-18 13:16:39 +00:00
sotaro
927d964708 Bug 1609598 - Fix stride in RendererRecordedFrame::GetSourceSurface() r=nical
Differential Revision: https://phabricator.services.mozilla.com/D60225

--HG--
extra : moz-landing-system : lando
2020-01-17 09:31:43 +00:00
Edwin Takahashi
9f3cc061e7 Bug 1608582 - tighten reftest annotation, part 3 r=jmaher
Changes:

Tighten reftest pixel differences now that reftest has been migrated fully over to ubuntu1804.

Differential Revision: https://phabricator.services.mozilla.com/D59595

--HG--
extra : moz-landing-system : lando
2020-01-11 12:32:52 +00:00
Sawyer Bergeron
83a4d63f1b Bug 1605755 Add touch acceleration r=botond
Adds exponential acceleration to touchpad pan events to improve percieved scrolling responsiveness

Platforms affected: Linux, any using PANDELTA_PAGE

Differential Revision: https://phabricator.services.mozilla.com/D58395

--HG--
extra : moz-landing-system : lando
2020-01-15 17:48:41 +00:00
Jeff Muizelaar
3ccd0cbeca Bug 1593574. Create an opaque surface for fallback when possible. r=mattwoodrow
This moves the opaqueness calculation out of if (blob) condition and
changes how we calculate the size of the fallback surface depending
on whether we have a compltely opaque snapped item or now.

This change allows scrollbars to marked as opaque on Windows which reduces the
GPU utilization in the DWM with DirectComposite on from 21% to 17% at 1080p and
29% to 24% at 4k

Differential Revision: https://phabricator.services.mozilla.com/D51557

--HG--
extra : moz-landing-system : lando
2020-01-14 19:37:42 +00:00