Граф коммитов

16395 Коммитов

Автор SHA1 Сообщение Дата
Brad Werth 5ad125fce1 Bug 1738926 Part 1: Check if sublayers need to be rebuilt. r=mstange
This fixes a correctness issue. Since NativeLayerCA Representations can
generate new CALayers under certain conditions, the NativeLayerRootCA must
check to see if a rebuild is necessary when committing.

Differential Revision: https://phabricator.services.mozilla.com/D131307
2021-11-18 21:28:44 +00:00
sotaro 136d8c49e7 Bug 1741123 - Remove LayersBackend::LAYERS_D3D11 r=gfx-reviewers,bradwerth,nical
Remove LayersBackend::LAYERS_D3D11 is not used any more.

Differential Revision: https://phabricator.services.mozilla.com/D131107
2021-11-18 21:27:48 +00:00
Dzmitry Malyshau 0f3e259c24 Bug 1740165 properly serialize mUseWebGPU r=sotaro
Differential Revision: https://phabricator.services.mozilla.com/D131448
2021-11-18 17:13:10 +00:00
Narcis Beleuzu ce6ad351e2 Backed out changeset 12736f9bf7b5 (bug 1741784) for compositor leakchecks. CLOSED TREE 2021-11-18 18:07:09 +02:00
sotaro 2dc3b69cde Bug 1741784 - Remove unused code around CompositableHost r=gfx-reviewers,nical
Differential Revision: https://phabricator.services.mozilla.com/D131466
2021-11-18 14:16:35 +00:00
sotaro f0775d8818 Bug 1741783 - Rename PuppetWidget::HasLayerManager() to HasWindowRenderer() r=gfx-reviewers,nical
PuppetWidget already renamed GetLayerManager() to GetWindowRenderer().

Differential Revision: https://phabricator.services.mozilla.com/D131465
2021-11-18 14:16:00 +00:00
sotaro 4f3833aa2f Bug 1741111 - Remove LayersBackend::LAYERS_BASIC r=gfx-reviewers,bradwerth
LayersBackend::LAYERS_BASIC is not used any more.

Differential Revision: https://phabricator.services.mozilla.com/D131104
2021-11-17 22:05:47 +00:00
sotaro a125f95885 Bug 1741352 - Relax widget size log in WebRenderLayerManager::Initialize() r=gfx-reviewers,bradwerth
We also want  a size check log in content process.

Differential Revision: https://phabricator.services.mozilla.com/D131210
2021-11-16 22:34:14 +00:00
Brad Werth 1b44cb44ee Bug 1737682 Part 1: Cache calls to NativeLayerCA::ShouldSpecializeVideo in a state bit. r=gfx-reviewers,mstange
This guarantees that any time mMutatedSpecializeVideo is set to true, the next
call to ApplyChanges will receive the value that actually triggered the
mutation. This was *probably* already true, but this change makes it explicit
and similar to other state changes.

Differential Revision: https://phabricator.services.mozilla.com/D129452
2021-11-16 20:55:44 +00:00
Andi-Bogdan Postelnicu c8e0f87391 Bug 1519636 - First reformat with clang-format 13.0.0. r=firefox-build-system-reviewers,sylvestre,mhentges
Updated with clang-format version 13.0.0 (taskcluster-OgjH5lasS5K_fvefdRcJVg)

Depends on D131114

Differential Revision: https://phabricator.services.mozilla.com/D129119
2021-11-16 08:07:30 +00:00
sotaro f4fdf11ff5 Bug 1738362 - Do not use MacIOSurface for video frame with RenderCompositorSWGL r=bradwerth,gfx-reviewers
RenderCompositorSWGL does not support MacIOSurface NV12 nor YUV422. Their usage causes a crash at SwCompositor::queue_composite(). See Bug 1697004.

On macOS, RenderCompositorSWGL is normally used only for headless.

Differential Revision: https://phabricator.services.mozilla.com/D131040
2021-11-16 01:58:49 +00:00
Tetsuharu Ohzeki 076dabcb2a Bug 1741175 - Remove unused GLBlitTextureImageHelper. r=gfx-reviewers,jgilbert,bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D131133
2021-11-16 00:53:16 +00:00
sotaro 096f8e103f Bug 1741121 - LayersBackend::LAYERS_CLIENT r=gfx-reviewers,jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D131106
2021-11-15 22:39:40 +00:00
sotaro d576be73d8 Bug 1740879 - Remove KnowsCompositor::DeviceCanReset() r=gfx-reviewers,jrmuizel
KnowsCompositor::DeviceCanReset() is not used.

Differential Revision: https://phabricator.services.mozilla.com/D131041
2021-11-12 23:28:05 +00:00
Hiroyuki Ikezoe 7243be3f7a Bug 1692708 - Add scrollTo and scrollTop test cases in helper_relative_scroll_smoothness.html. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D129595
2021-11-12 07:54:18 +00:00
Hiroyuki Ikezoe b11e8dcd33 Bug 1692708 - Transmogrify ScrollToCSSPixels to ScrollByCSSPixels if there's any on-going APZ animation and there's no on-going async scroll by script. r=botond
test_abort_smooth_scroll_by_instant_scroll.html in this comment is a test case
to make sure this change doesn't regress a case where a smoothe scrolling run
by an APZC is replaced by an instant scroll operation by script.

Some other mochitests for this change are in the next commit.

Differential Revision: https://phabricator.services.mozilla.com/D129594
2021-11-12 07:54:17 +00:00
Hiroyuki Ikezoe db5de169ad Bug 1692708 - Add cancelScrollAnimation and use it in window_bug1369072.html and browser_scroll.js. r=botond
Both window_bug1369072.html and browser_scroll.js have a pattern something like;

1) Call synthesizeKey to scroll an element
2) Wait a scroll event
3) Test something
4) (Re)set the scroll position to (0, 0) by calling Element.scrollTop and
   Element.scrollLeft or scrollTo.

With the new transmogrification the step 4) will not reset the scroll position
if there's an on-going scroll animation in APZ triggered by the synthesizeKey.

To avoid the situation where there's an on-going animation at the step 4), we
destroy the corresponding scrollable frame and reconstruct it so that it
clobbers the animation.

Differential Revision: https://phabricator.services.mozilla.com/D130852
2021-11-12 07:54:17 +00:00
Hiroyuki Ikezoe cd625240a9 Bug 1692708 - Run helper_relative_scroll_smoothness.html with native key events both on Windows and Mac. r=botond
synthesizeKey() just invokes a corresponding command. In "KEY_ArrowDown" case
it's nsISelectionController::ScrollLine [1] which is actually
PresShell::ScrollLine which calls nsIScrollable::ScrollBy, that's not what we
wanted to test for bug 1692707. To exercise APZ's keyboard scrolling we need to
use synthesizeNativeKey instead.

[1] https://searchfox.org/mozilla-central/rev/126f016b59513988fae56c2b3f69c1cd23fe6ca1/dom/base/nsGlobalWindowCommands.cpp#363-364

Differential Revision: https://phabricator.services.mozilla.com/D129593
2021-11-12 07:54:17 +00:00
Hiroyuki Ikezoe d547020761 Bug 1692708 - Run helper_relative_scroll_smoothness.html with mouse wheel events. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D129592
2021-11-12 07:54:16 +00:00
Hiroyuki Ikezoe 1b31384027 Bug 1692708 - Specify MOUSESCROLL_SCROLL_LINES in synthesizeNativeWheel if apz.test.mac.synth_wheel_input is true. r=tnikkel
Without specifying the value, even if synthesizeNativeWheel causes wheel inputs,
it will be converted to an instant scroll rather than smooth. In fact on Mac
mouse wheeling causes this type of events that is that the events'
hasPreciseScrollingDeltas flag is false.

Differential Revision: https://phabricator.services.mozilla.com/D129591
2021-11-12 07:54:16 +00:00
Hiroyuki Ikezoe 4dbf08ba04 Bug 1692708 - Await promiseApzFlushedRepaints() before calling window.scrollTo(). r=tnikkel
This is the way what other similar tests do (e.g.
helper_zoomToFocusedInput_multiline.html [1] and
helper_zoomToFocusedInput_scroll.html [2]).


[1] https://searchfox.org/mozilla-central/rev/126f016b59513988fae56c2b3f69c1cd23fe6ca1/gfx/layers/apz/test/mochitest/helper_zoomToFocusedInput_multiline.html#35-36
[2] https://searchfox.org/mozilla-central/rev/126f016b59513988fae56c2b3f69c1cd23fe6ca1/gfx/layers/apz/test/mochitest/helper_zoomToFocusedInput_scroll.html#33-34

Differential Revision: https://phabricator.services.mozilla.com/D129590
2021-11-12 07:54:16 +00:00
Lee Salzman 3c994f8afd Bug 1739448 - Implement a prototype WebGL-backed Canvas2D. r=gfx-reviewers,nical,jrmuizel
This mainly provides DrawTargetWebgl, which implements the subset of the DrawTarget
API necessary for integration with CanvasRenderingContext2D. It translates them to
suitable commands for its internal ClientWebGLContext, which then manages remoting
WebGL requests to the parent/GPU process.

Currently two shaders are used for drawing Canvas2D primitives, but can be expanded
in the future. These are an image shader and a solid color shader.

The core of this implementation revolves around TexturePacker and TextureHandle,
which cope with the necessity of frequently uploading SourceSurfaces for use with
WebGL. TexturePacker implements a bin-packing algorithm for packing these uploads
into texture pages, which can either be SharedTextures if they are reasonably small,
or StandaloneTextures if they are too big to pack in a SharedTexture. Each upload
is assigned a TextureHandle which is used to manage it in a move-to-front cache,
so that we can easily eject TextureHandles from the back of the cache if we have
too many. These TextureHandles are associated with the SourceSurface that spawned
them to more easily manage their lifetimes.

There are further dependent caches for dealing with blurred shadows and with text.
Shadows are cached in an uploaded texture bound to the SourceSurface that generated
them. Text is handled by caching entire runs in the GlyphCache (keyed by both their
rendering parameters and their glyphs). The text is first rasterized to a surface
and then uploaded to a texture in the GlyphCache which can be reused should the
text be encountered again.

To deal with commands we can't accelerate, a separate internal DrawTargetSkia is
also maintained. The content of the WebGL framebuffer is copied into it so that
drawing can then proceed in software from there. It remains in this fallover state
until the next frame, when it resets back to using the WebGL framebuffer again.

This acceleration is disabled by default. To enable it, you must toggle the pref
"gfx.canvas.accelerated" to true. This should be suitably different from the naming
of the previous SkiaGL prefs to not alias with them. There are a few dependent prefs
that follow from the previous SkiaGL prefs for setting the size limitations for
acceleration and also limitations for the internal texture cache.

Differential Revision: https://phabricator.services.mozilla.com/D130388
2021-11-11 07:16:58 +00:00
Marian-Vasile Laza 748933bf4b Backed out 2 changesets (bug 1739448) for causing geckoview failures on 1246775-1.html. CLOSED TREE
Backed out changeset 7b82837e2f56 (bug 1739448)
Backed out changeset feac99f1dae3 (bug 1739448)
2021-11-11 07:39:10 +02:00
Lee Salzman c3d10f0f9e Bug 1739448 - Implement a prototype WebGL-backed Canvas2D. r=gfx-reviewers,nical,jrmuizel
This mainly provides DrawTargetWebgl, which implements the subset of the DrawTarget
API necessary for integration with CanvasRenderingContext2D. It translates them to
suitable commands for its internal ClientWebGLContext, which then manages remoting
WebGL requests to the parent/GPU process.

Currently two shaders are used for drawing Canvas2D primitives, but can be expanded
in the future. These are an image shader and a solid color shader.

The core of this implementation revolves around TexturePacker and TextureHandle,
which cope with the necessity of frequently uploading SourceSurfaces for use with
WebGL. TexturePacker implements a bin-packing algorithm for packing these uploads
into texture pages, which can either be SharedTextures if they are reasonably small,
or StandaloneTextures if they are too big to pack in a SharedTexture. Each upload
is assigned a TextureHandle which is used to manage it in a move-to-front cache,
so that we can easily eject TextureHandles from the back of the cache if we have
too many. These TextureHandles are associated with the SourceSurface that spawned
them to more easily manage their lifetimes.

There are further dependent caches for dealing with blurred shadows and with text.
Shadows are cached in an uploaded texture bound to the SourceSurface that generated
them. Text is handled by caching entire runs in the GlyphCache (keyed by both their
rendering parameters and their glyphs). The text is first rasterized to a surface
and then uploaded to a texture in the GlyphCache which can be reused should the
text be encountered again.

To deal with commands we can't accelerate, a separate internal DrawTargetSkia is
also maintained. The content of the WebGL framebuffer is copied into it so that
drawing can then proceed in software from there. It remains in this fallover state
until the next frame, when it resets back to using the WebGL framebuffer again.

This acceleration is disabled by default. To enable it, you must toggle the pref
"gfx.canvas.accelerated" to true. This should be suitably different from the naming
of the previous SkiaGL prefs to not alias with them. There are a few dependent prefs
that follow from the previous SkiaGL prefs for setting the size limitations for
acceleration and also limitations for the internal texture cache.

Differential Revision: https://phabricator.services.mozilla.com/D130388
2021-11-11 04:33:50 +00:00
Nika Layzell d73755617d Bug 1732343 - Part 2: Migrate all uses of base::FileDescriptor to UniqueFileHandle, r=handyman
This is useful for the following parts, as UniqueFileHandle is a cross-platform
type which can also be used to support transferring HANDLEs between processes.

This change requires fairly sweeping changes to existing callsites, which
previously did not require owning access to the handle types when transferring.
For the most part these changes were straightforward, but manual.

Differential Revision: https://phabricator.services.mozilla.com/D126564
2021-11-09 14:17:32 +00:00
Michelle Goossens bd6ee3c71c Bug 1727943 - Re-enable Windows 10 x64 2004 CCov tests that were forgotten r=jmaher
Differential Revision: https://phabricator.services.mozilla.com/D130715
2021-11-09 12:55:22 +00:00
Hiroyuki Ikezoe 9816dd2b16 Bug 1739541 - Introduce APZScrollAnimationType and use it in RepaintRequest and ScrollFrameHelopr instead of a boolean representing whether there's an animation or not. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D130421
2021-11-09 09:19:26 +00:00
Hiroyuki Ikezoe d858a93e39 Bug 1739541 - Introduce WasTriggeedByScript() function in AsyncPanZoomAnimation class. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D130420
2021-11-09 09:19:26 +00:00
Gerald Squelart 2a8eb1038b Bug 1738627 - profiler_thread_is_being_profiled's ThreadProfilingFeatures is now compulsory - r=canaltinova
Now that most calls to `profiler_thread_is_being_profiled` have been updated, the `ThreadProfilingFeatures` can be made compulsory, to force callers to think about what they really want to know about the current profiling state.

Differential Revision: https://phabricator.services.mozilla.com/D130010
2021-11-08 23:59:36 +00:00
Gerald Squelart 5399574d8b Bug 1738627 - profiler_thread_is_being_profiled_for_markers - r=canaltinova
`profiler_thread_is_being_profiled` is used a lot for markers, so it makes sense to have a specialized version, which is a bit shorter, and lives in ProfilerMarkers.h.

Differential Revision: https://phabricator.services.mozilla.com/D130009
2021-11-08 23:59:35 +00:00
Gerald Squelart 27166e1256 Bug 1739500 - Modernize lambda that adds a screenshot marker - r=canaltinova
While working on this screenshot marker, I noticed that the lambda initialization could directly copy or move its needed captures, instead of going through separate copies on the stack, which was probably done before C++14 lambda were available to us.

Differential Revision: https://phabricator.services.mozilla.com/D130436
2021-11-07 22:43:12 +00:00
Gerald Squelart 9784494cbd Bug 1739500 - De-duplicate "CompositorScreenshot" marker types - r=canaltinova
There were two structs claiming to be "CompositorScreenshot", which is not allowed. It was working because the JSON output was compatible, and handled in a special way in the front-end.
But it's better to combine the two structs into one, for consistency with other markers, and lower maintainability risks.

Differential Revision: https://phabricator.services.mozilla.com/D130435
2021-11-07 22:43:12 +00:00
sotaro bf1f700f2b Bug 1739621 - Remove remaining UseAdvancedLayers() r=jrmuizel,gfx-reviewers,bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D130467
2021-11-07 12:44:53 +00:00
sotaro e13c31b137 Bug 1739553 - Use wr::ExternalImageId in more places r=gfx-reviewers,bradwerth
It could make code more explicit.

Differential Revision: https://phabricator.services.mozilla.com/D130434
2021-11-07 07:26:45 +00:00
Botond Ballo dac9173b80 Bug 1739663 - Avoid a debug assertion on shutdown in InputQueue::Clear(). r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D130521
2021-11-07 03:04:14 +00:00
Botond Ballo 977ef592c8 Bug 1739754 - Remove vestiges of class KeyboardScrollAnimation which no longer exists. r=tnikkel
Depends on D130532

Differential Revision: https://phabricator.services.mozilla.com/D130533
2021-11-06 05:21:07 +00:00
Botond Ballo d1c9489dc6 Bug 1739754 - Fix an out-of-date commment. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D130532
2021-11-06 05:21:07 +00:00
Jeff Muizelaar 1bc2d91d64 Bug 1739551 - Don't bother storing the group bounds. r=mstange
We don't use it for anything anymore.

Differential Revision: https://phabricator.services.mozilla.com/D130432
2021-11-05 20:39:02 +00:00
Jeff Muizelaar b3adb549de Bug 1739542 - Switch a bunch of IntRects to LayerRects. r=mstange
This makes the coordinate space more obvious. They were IntRects to make it
easier during development to be sloppy.

Differential Revision: https://phabricator.services.mozilla.com/D130423
2021-11-05 20:25:23 +00:00
Cristian Tuns cbd178830f Backed out 10 changesets (bug 1732343) for causing coverage build bustages (Bug 1739590).
Backed out changeset bba94c79f3e1 (bug 1732343)
Backed out changeset d30fa1e1f605 (bug 1732343)
Backed out changeset ed0b4f757c4b (bug 1732343)
Backed out changeset a272da134c34 (bug 1732343)
Backed out changeset ccb259d73843 (bug 1732343)
Backed out changeset a292990b62de (bug 1732343)
Backed out changeset 7d1854782ca8 (bug 1732343)
Backed out changeset 29eaabd9ffb3 (bug 1732343)
Backed out changeset 1aa26657a7a6 (bug 1732343)
Backed out changeset 7a6708dc620a (bug 1732343)
2021-11-05 07:21:04 -04:00
Cristian Tuns 1aeac93d23 Backed out 5 changesets (bug 1738627) for causing xpcshell failures on test_ext_geckoProfiler_schema.js CLOSED TREE
Backed out changeset 42d385d7da97 (bug 1738627)
Backed out changeset edeb3a338954 (bug 1738627)
Backed out changeset 98f02e35134d (bug 1738627)
Backed out changeset 711daa6dd24b (bug 1738627)
Backed out changeset 49e12753a40c (bug 1738627)
2021-11-05 05:12:28 -04:00
Gerald Squelart ffc00218c3 Bug 1738627 - profiler_thread_is_being_profiled's ThreadProfilingFeatures is now compulsory - r=canaltinova
Now that most calls to `profiler_thread_is_being_profiled` have been updated, the `ThreadProfilingFeatures` can be made compulsory, to force callers to think about what they really want to know about the current profiling state.

Differential Revision: https://phabricator.services.mozilla.com/D130010
2021-11-05 05:52:29 +00:00
Gerald Squelart 7fa084ae7c Bug 1738627 - profiler_thread_is_being_profiled_for_markers - r=canaltinova
`profiler_thread_is_being_profiled` is used a lot for markers, so it makes sense to have a specialized version, which is a bit shorter, and lives in ProfilerMarkers.h.

Differential Revision: https://phabricator.services.mozilla.com/D130009
2021-11-05 05:52:28 +00:00
Nika Layzell b8279164db Bug 1732343 - Part 2: Migrate all uses of base::FileDescriptor to UniqueFileHandle, r=handyman
This is useful for the following parts, as UniqueFileHandle is a cross-platform
type which can also be used to support transferring HANDLEs between processes.

This change requires fairly sweeping changes to existing callsites, which
previously did not require owning access to the handle types when transferring.
For the most part these changes were straightforward, but manual.

Differential Revision: https://phabricator.services.mozilla.com/D126564
2021-11-04 19:20:17 +00:00
Andrew Osmond 01be1b4367 Bug 1734649 - Part 3. Switch to always allocating PWebGL instances via CanvasManager. r=jgilbert
This patch causes us to move WebGL execution in the compositor process
from the Compositor thread to the Renderer thread. This has the
advantage of keeping all of our GL calls on the same thread, which makes
us work more like a typical application. This makes the drivers happy,
especially on Linux, and may allow us to move forward with OOP WebGL on
Linux.

Differential Revision: https://phabricator.services.mozilla.com/D127903
2021-11-04 16:29:44 +00:00
Andrew Osmond cdc239b74f Bug 1734649 - Part 2. Create PCanvasManager to manage WebGL instances. r=jrmuizel
This patch adds the necessary IPDL plumbing to allow us to create WebGL
instances off the main thread in the content process, and to execute
them on the Renderer thread in the compositor process.

Differential Revision: https://phabricator.services.mozilla.com/D127839
2021-11-04 16:29:44 +00:00
Nicolas Silva 51efadfa3e Bug 1737648 - Don't batch uploads for items larger than a certain size. r=gfx-reviewers,bradwerth
The default size on most platforms is 256*256 which corresponds to the default blob tile size. I didn't check on android so I set it to 512*512 above which we never batch the upload so that the behavior is unchanged, but I suspect that a smaller threshold like 256*256 would also work better there.

On Windows with heavy blob image workloads, not batching gives a 20%-30% improvement to the time spent in update_texture_cache.

Differential Revision: https://phabricator.services.mozilla.com/D129516
2021-11-03 16:42:42 +00:00
Masayuki Nakano 4341d6fb0c Bug 1455514 - part 1: Add accessors and static helper methods to retrieve `nsINode` or its concrete classes from `EventTarget` r=smaug
Currently, checking whether an `EventTarget` is `nsINode` (or its concrete
classes) or not requires a QI, but it's expensive and used a lot while we
handle each event.  Therefore, it'd be nicer for creating a virtual method,
`EventTarget::IsNode()` and use it for the check.

If trying to convert `EventTarget` to a concrete class, it may require two
virtual method calls.  I'm not sure whether it's cheaper than a QI, but at
least, it won't depend on the UUID check order of `QueryInterface()` when
multiple interfaces are implemented.

Differential Revision: https://phabricator.services.mozilla.com/D129781
2021-11-02 13:03:43 +00:00
Botond Ballo f5de659316 Bug 1738152 - Remove WebRenderScrollDataWrapper methods that are no longer used. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129769
2021-10-29 22:30:17 +00:00
Botond Ballo 2237232282 Bug 1738152 - Remove HitTestingTreeNode::mEventRegions. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129768
2021-10-29 22:30:16 +00:00
Botond Ballo 895d9edebf Bug 1738152 - Remove APZCTreeManager::ComputeClipRegion(). r=hiro
Depends on D129767

Differential Revision: https://phabricator.services.mozilla.com/D129770
2021-10-29 22:30:16 +00:00
Botond Ballo 6f49f7645f Bug 1738152 - Remove TreeBuildingState::mParentHasPerspective. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129767
2021-10-29 22:30:15 +00:00
Botond Ballo cfffffeb35 Bug 1738152 - Remove HitTestingTreeNode::mClipRegion. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129766
2021-10-29 22:30:15 +00:00
Botond Ballo b032de8ef1 Bug 1738152 - Remove HitTestingTreeNode::mIsBackfaceHidden. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129765
2021-10-29 22:30:15 +00:00
Botond Ballo fe3b6a1828 Bug 1738152 - Remove HitTestingTreeNode methods that were only used by InternalHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129764
2021-10-29 22:30:14 +00:00
Botond Ballo 441e0d7e8c Bug 1738152 - Remove the aOutSourceOfOverscrollTransform parameter of APZCTreeManager::ComputeTransformForNode(). r=hiro
This parameter was only used by InternalHitTester.

Differential Revision: https://phabricator.services.mozilla.com/D129763
2021-10-29 22:30:14 +00:00
Botond Ballo c2ac235ed4 Bug 1738152 - Remove IAPZHitTester methods that were only used by InternalHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129762
2021-10-29 22:30:14 +00:00
Emilio Cobos Álvarez 4cfc1d8874 Bug 1738265 - Teach some popup tests to deal with popups having margins by default. r=NeilDeakin
For tests that actually test margin handling I've just removed the default
margin by adding:

  <?xml-stylesheet href="data:text/css,menupopup{margin: 0}" type="text/css"?>

The other tests I've just fixed by accounting for the margins.

Differential Revision: https://phabricator.services.mozilla.com/D129866
2021-10-29 19:26:37 +00:00
Hiroyuki Ikezoe 0713dc0d2f Bug 1738385 - Drop APZSampler::AdvanceAnimations and relevant stuff. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D129885
2021-10-29 02:58:17 +00:00
Botond Ballo c4ac87dc57 Bug 1731700 - Remove InternalHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129760
2021-10-29 00:28:15 +00:00
Botond Ballo c8e6aa3f43 Bug 1731700 - Do not use InternalHitTester in TestWRScrollData.cpp. r=hiro
These tests do not actually perform hit testing.

Differential Revision: https://phabricator.services.mozilla.com/D129759
2021-10-29 00:28:15 +00:00
Botond Ballo 768f90d96d Bug 1731700 - Port TestScrollHandoff to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129758
2021-10-29 00:28:14 +00:00
Botond Ballo c36abc16e2 Bug 1731700 - Port TestOverscroll to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129757
2021-10-29 00:28:14 +00:00
Botond Ballo bd7577dfaf Bug 1731700 - Port TestEventResult to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129756
2021-10-29 00:28:13 +00:00
Botond Ballo 0c5b51962e Bug 1731700 - Port TestEventRegions to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129755
2021-10-29 00:28:13 +00:00
Botond Ballo 0f2cef803a Bug 1731700 - Port TestSnappingOnMomentum to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129754
2021-10-29 00:28:13 +00:00
Botond Ballo ba4265ea15 Bug 1731700 - Port TestSnapping to use MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129753
2021-10-29 00:28:12 +00:00
Botond Ballo af64ff1887 Bug 1731700 - Introduce MockHitTester. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129752
2021-10-29 00:28:12 +00:00
Brad Werth c2562b0917 Bug 1737998: Prevent macOS 10.12 from using specialized video layers. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D129869
2021-10-28 22:47:10 +00:00
Sandor Molnar f5bbecdcc2 Backed out 13 changesets (bug 1711061) on devs request. CLOSED TREE
Backed out changeset c4f073f7e3a3 (bug 1711061)
Backed out changeset aced4b672fb4 (bug 1711061)
Backed out changeset 3687e798f665 (bug 1711061)
Backed out changeset 7b471990ea86 (bug 1711061)
Backed out changeset 1014a95f540e (bug 1711061)
Backed out changeset a37b3091281d (bug 1711061)
Backed out changeset 96a0ef35881b (bug 1711061)
Backed out changeset 38890cc266fb (bug 1711061)
Backed out changeset be73004c0850 (bug 1711061)
Backed out changeset b964576ae53d (bug 1711061)
Backed out changeset d453c5219255 (bug 1711061)
Backed out changeset 0145b538175b (bug 1711061)
Backed out changeset 41ba2e2a2d13 (bug 1711061)
2021-10-29 00:36:30 +03:00
Florian Quèze 1c3f80fe51 Bug 1738285 - move AUTO_PROFILE_FOLLOWING_RUNNABLE to its own header, r=gerald.
Differential Revision: https://phabricator.services.mozilla.com/D129825
2021-10-28 20:35:06 +00:00
Brad Werth 63e3c22a38 Bug 1731956: Make NativeLayerRootCA fullscreen and mouse move accessors thread safe. r=mstange
In addition to adding locks around the accessors, this also removes the call
to `CommitToScreen` from the fullscreen accessor, which was probably
redundant and definitely made the main thread call `Commit` which introduces
possible concurrency errors.

Differential Revision: https://phabricator.services.mozilla.com/D129425
2021-10-27 20:46:29 +00:00
Andrew Osmond c49ed44331 Bug 1711061 - Part 13. Remove the now unused ImageContainer and related code for images. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D126606
2021-10-27 01:24:36 +00:00
Andrew Osmond c6eb106f04 Bug 1711061 - Part 12. Change the display list to use WebRenderImageProvider. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D126605
2021-10-27 01:24:35 +00:00
Andrew Osmond d46a011943 Bug 1711061 - Part 7. Remove support for ImageContainer-based SVG image blob recordings. r=tnikkel
This will be replaced by a WebRenderImageProvider-based implementation
in a later part in this series.

Differential Revision: https://phabricator.services.mozilla.com/D126600
2021-10-27 01:24:33 +00:00
Sandor Molnar 6632079d8d Backed out 13 changesets (bug 1711061) for causing browser-chrome failures in test/performance/browser_startup_images. CLOSED TREE
Backed out changeset 5988220f56b8 (bug 1711061)
Backed out changeset cb7721d7ce49 (bug 1711061)
Backed out changeset 343746ffae73 (bug 1711061)
Backed out changeset 000940244dcf (bug 1711061)
Backed out changeset 27565d5ae08d (bug 1711061)
Backed out changeset f3b2379d971b (bug 1711061)
Backed out changeset d4b3d0fa1771 (bug 1711061)
Backed out changeset 9af5b3f2225f (bug 1711061)
Backed out changeset da992effeff1 (bug 1711061)
Backed out changeset 6b2bc6c16b9f (bug 1711061)
Backed out changeset ac2792d42be2 (bug 1711061)
Backed out changeset cb00177e655e (bug 1711061)
Backed out changeset 8d5261184226 (bug 1711061)
2021-10-26 18:04:34 +03:00
Andrew Osmond 6ee464104f Bug 1711061 - Part 13. Remove the now unused ImageContainer and related code for images. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D126606
2021-10-26 13:28:27 +00:00
Andrew Osmond 0ac282d26a Bug 1711061 - Part 12. Change the display list to use WebRenderImageProvider. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D126605
2021-10-26 13:28:27 +00:00
Andrew Osmond ca9bcdf869 Bug 1711061 - Part 7. Remove support for ImageContainer-based SVG image blob recordings. r=tnikkel
This will be replaced by a WebRenderImageProvider-based implementation
in a later part in this series.

Differential Revision: https://phabricator.services.mozilla.com/D126600
2021-10-26 13:28:25 +00:00
Botond Ballo d724f3c3f3 Bug 1730606 - Port APZHitTestingTesterInternal.ComplexMultiLayerTree to mochitest. r=hiro
In this case, the gtest is retained as it makes other assertions
(related to the APZC tree structure) which are useful. However,
it no longer makes hit-testing assertions, and no longer uses
InternalHitTester.

Differential Revision: https://phabricator.services.mozilla.com/D129352
2021-10-25 22:19:06 +00:00
Botond Ballo b10b847642 Bug 1730606 - Port APZHitTestingTesterInternal.HitTesting3 to mochitest. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129335
2021-10-25 22:19:06 +00:00
Botond Ballo 5830b09df1 Bug 1730606 - Port APZHitTestingTesterInternal.HitTesting2 to mochitest. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129334
2021-10-25 22:19:05 +00:00
Botond Ballo 84ce017af8 Bug 1730606 - Port APZHitTestingTesterInternal.HitTesting1 to mochitest. r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D129333
2021-10-25 22:19:05 +00:00
Hiroyuki Ikezoe 03c7bc1cfa Bug 1708697 - Make sure all pending paints have been done in flushApzRepaintsInPopup. r=tnikkel
And rename the function to promiseApzFlushedRepaintsInPopup since now the
funciton does the same thing what promiseApzFlushedRepaints does.

Depends on D129365

Differential Revision: https://phabricator.services.mozilla.com/D129366
2021-10-25 09:08:09 +00:00
Hiroyuki Ikezoe f44e6b0412 Bug 1708697 - Make sure a scroll event was fired in the same manner as we did for a mousemove event in the previous commit. r=tnikkel
Depends on D129364

Differential Revision: https://phabricator.services.mozilla.com/D129365
2021-10-25 09:08:09 +00:00
Hiroyuki Ikezoe dd5dc888d7 Bug 1708697 - Make sure a mousemove event has been received in the popup content before starting autoscrolling. r=tnikkel
If we start autoscrolling without moving the mouse position into the content
area, we do sample with undesirable scroll deltas in
AutoscrollAnimation::DoSample since the initial mouse position is outside of the
popup window.

Note that to make sure an event listener mousemove events is set in the popup
content before causing a mousemove event from the browser parent process we need
to add the event listener in the extension's popup context in the first place.
That's because __not awaiting__ a SpecialPowers.spawn() with an addEventListener
call in the spawned context doesn't ensure the script in the spawned context
runs. We will do the same manner for a scroll event in the next change.

Differential Revision: https://phabricator.services.mozilla.com/D129364
2021-10-25 09:08:09 +00:00
Brad Werth 6603a4e814 Bug 1734854: Make NativeLayerRootCA avoid changing sublayers when it has no effect. r=gfx-reviewers,jrmuizel
When isolating video layers, changes to sublayers that we are already ignoring
should not cause us to change our sublayers. This patch checks to see if the
changes to sublayers can all be safely ignored.

Differential Revision: https://phabricator.services.mozilla.com/D129330
2021-10-23 03:39:10 +00:00
Andrew Osmond ae8d706579 Bug 1709679 - Properly map/unmap SourceSurfaceSharedDataWrapper for blob recordings. r=jrmuizel
When replaying blob recordings, we need to ensure that we map and unmap
the surface properly so that we don't accidently expire the mapping too
early to free up virtual memory on 32-bit Firefox. The code was written
but not activated because we failed to use the wrong type in the
SourceSurfaceSharedDataWrapper::GetType implementation.

Differential Revision: https://phabricator.services.mozilla.com/D129311
2021-10-22 20:41:39 +00:00
Hiroyuki Ikezoe 7e2565109e Bug 1692707 - Shift sampled scroll offsets with the delta rather than clobbering them with the latest one in the case of relative scroll updates. r=botond
helper_relative_scroll_smoothness.html is basically based on the test case
Markus attached in bug 1692707 comment 0 (which is a really great test case!).
It expands its content and changes the root scroller's scroll position
periodically and causes a 100ms jank every 300ms. In the meantime the parent
process tries to send arrow down key press events so that the helper content is
scrolled by APZ. Without this fix, there will appear same scroll offsets when
the scroll position is changed in the content because it clobbers
previously-sampled scroll offsets, with this fix it won't happen.

Differential Revision: https://phabricator.services.mozilla.com/D128704
2021-10-22 10:31:36 +00:00
Hiroyuki Ikezoe 414b62eade Bug 1692707 - Add sampled scroll offsets field in APZTestData to evaluate scroll _smoothness_ in mochitests. r=botond,emilio
Differential Revision: https://phabricator.services.mozilla.com/D128827
2021-10-22 10:14:15 +00:00
Brad Werth 557ceaac29 Bug 1732694: Prevent NativeLayerRootCA from isolating video layers while mouse is moving. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D129065
2021-10-20 22:40:26 +00:00
Jeff Muizelaar 702a09ee6d Bug 1736705 - Use ScreenReference DrawTarget instead of creating one from scratch. r=aosmond
This reduces the overhead (mostly heap allocations) when there are lots
of individual layers like on the SVG bouncing circles motionmark test.
https://share.firefox.dev/3jihjfc

Differential Revision: https://phabricator.services.mozilla.com/D129047
2021-10-20 16:45:59 +00:00
Jeff Muizelaar 28e09f13a1 Bug 1736697 - Remove code for checking layer size. r=mstange
The users of this were removed with FrameLayerBuilder.
Two callers that passed true remained: one was a print
statement, and the other should be fine to change.

Differential Revision: https://phabricator.services.mozilla.com/D128946
2021-10-20 16:33:04 +00:00
Andreea Pavel ab1193e806 Bug 1736530 - fix pretty/prettier lint on a CLOSED TREE 2021-10-20 02:29:14 +03:00
Hiroyuki Ikezoe 5d773fb0b0 Bug 1708697 - Setup a scroll event listener before triggering an autoscroll operation. r=tnikkel
Depends on D128953

Differential Revision: https://phabricator.services.mozilla.com/D128954
2021-10-19 22:42:15 +00:00
Hiroyuki Ikezoe 6fb642f75a Bug 1708697 - Use SpecialPowers.pushPrefEnv instead of setBoolPref. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D128953
2021-10-19 22:42:15 +00:00
Timothy Nikkel 46bd33f0f5 Bug 1736530. Enable gfx/layers/apz/test/mochitest/helper_fission_animation_styling_in_transformed_oopif.html. r=hiro
This test was disabled for webrender because of an assert. The mentioned bug is resolved and doesn't seem to mention this test at all. I pushed to try and it seems to pass now. So let's enable it.

Differential Revision: https://phabricator.services.mozilla.com/D128862
2021-10-19 22:24:11 +00:00
Brad Werth 4f808bf352 Bug 1736446: Make NativeLayerCA consistently protect member access with a lock. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D128791
2021-10-19 20:48:56 +00:00
Joel Maher fed2831742 Bug 1727943 - turn on mochitest* tests that were skipped on win10-ccov and now pass. r=MasterWayZ
Differential Revision: https://phabricator.services.mozilla.com/D128817
2021-10-19 20:01:29 +00:00
Butkovits Atila 8ecb76d03a Backed out changeset 9d531fd67a5f (bug 1736446) for causing failures at Mutex_posix.cpp. CLOSED TREE 2021-10-19 23:09:26 +03:00