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

3198 Коммитов

Автор SHA1 Сообщение Дата
Botond Ballo d155669472 Bug 1917669 - Document the purpose of nsDisplayList::mIsRelativeToLayoutViewport. r=hiro DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D221536
2024-09-09 21:09:47 +00:00
Botond Ballo 16bc52cd2d Bug 1915051 - Add an assertion to ensure hit testing and rendering are not out of sync. r=hiro,tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D220201
2024-09-08 21:37:18 +00:00
Emilio Cobos Álvarez be6329111c Bug 1891335 - Compute EffectInfo updates at IntersectionObserver time. r=smaug,hiro
What goes on here is that there's a couple of unfortunate style change
sequences which end up making us not do the EffectsInfo dance correctly.

Twitter uses (maybe didn't use to, which would explain the regression) a
visibility: hidden, out-of-flow iframe for a bit (which we correctly
throttle). But then they switch to an in-flow, visible, zero-height
iframe. That we should _not_ throttle. However, we end up not getting to
the display list code at all, because nsBlockFrame decides that we don't
need to descend into an empty line[1].

It seems less error prone to re-use the IntersectionObserver timing and
computation to determine whether the iframe is visible. That completely
matches in-process iframes, too.

Removing the empty frame border and putting them on an empty line in
dom/base/test/test_bug1639328.html is enough to reproduce the issue
without this patch.

[1]: https://searchfox.org/mozilla-central/rev/fe2743c6c5c708061c7f6504b26958fcc815bb4a/layout/generic/nsBlockFrame.cpp#7569-7579

Differential Revision: https://phabricator.services.mozilla.com/D207479
2024-09-06 16:04:57 +00:00
Stanca Serban fe1949a695 Backed out changeset 80db8b7ff2af (bug 1891335) for causing mochitests failures in test_bug1639328.html. 2024-09-06 00:22:51 +03:00
Emilio Cobos Álvarez 61a57e6c46 Bug 1891335 - Compute EffectInfo updates at IntersectionObserver time. r=smaug,hiro
What goes on here is that there's a couple of unfortunate style change
sequences which end up making us not do the EffectsInfo dance correctly.

Twitter uses (maybe didn't use to, which would explain the regression) a
visibility: hidden, out-of-flow iframe for a bit (which we correctly
throttle). But then they switch to an in-flow, visible, zero-height
iframe. That we should _not_ throttle. However, we end up not getting to
the display list code at all, because nsBlockFrame decides that we don't
need to descend into an empty line[1].

It seems less error prone to re-use the IntersectionObserver timing and
computation to determine whether the iframe is visible. That completely
matches in-process iframes, too.

Removing the empty frame border and putting them on an empty line in
dom/base/test/test_bug1639328.html is enough to reproduce the issue
without this patch.

[1]: https://searchfox.org/mozilla-central/rev/fe2743c6c5c708061c7f6504b26958fcc815bb4a/layout/generic/nsBlockFrame.cpp#7569-7579

Differential Revision: https://phabricator.services.mozilla.com/D207479
2024-09-05 17:16:12 +00:00
Emilio Cobos Álvarez fe940af53e Bug 1915206 - Simplify SVG transforms a bit more. r=longsonr
We no longer need the concept of "local" transforms after bug 878346.

Local transforms that we'd need in the future could be represented via
attribute mapping.

We still need the viewbox transform shenanigans which applies to
children only, tho.

Differential Revision: https://phabricator.services.mozilla.com/D220290
2024-08-27 21:14:28 +00:00
Stanca Serban 0ad978c2a4 Backed out changeset 17ab0ddaa303 (bug 1915051) for causing mochitests crashes. 2024-08-27 06:53:07 +03:00
Botond Ballo da211ea30b Bug 1915051 - Add an assertion to ensure hit testing and rendering are not out of sync. r=hiro,tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D220201
2024-08-27 01:59:23 +00:00
Zach Hoffman 3929b2eab0 Bug 1914777 - Use cbindgen for border-image-repeat. r=firefox-style-system-reviewers,layout-reviewers,emilio
nsStyleBorder field mBorderImageRepeat replaces fields
mBorderImageRepeatH and mBorderImageRepeatY.

Differential Revision: https://phabricator.services.mozilla.com/D220074
2024-08-25 15:57:04 +00:00
Zach Hoffman 11860bb190 Bug 1914777 - Use cbindgen for StyleBorderImageRepeatKeyword. r=firefox-style-system-reviewers,layout-reviewers,emilio
Generated enum StyleBorderImageRepeatKeyword replaces enum StyleBorderImageRepeat.

Differential Revision: https://phabricator.services.mozilla.com/D220073
2024-08-25 15:57:04 +00:00
Emilio Cobos Álvarez 4aa1ad81ba Bug 878346 - Make transform a mapped attribute for SVG. r=longsonr,firefox-style-system-reviewers,zrhoffman
The tricky bit is rotate() which in SVG means something different if
there's an origin (you translate-then-untranslate it).

But this seems to work off-hand, and fix the reminder of bug 1906261.

Differential Revision: https://phabricator.services.mozilla.com/D215788
2024-08-21 15:00:48 +00:00
tannal bac095e83a Bug 1913213 - Remove unused nsDisplayListBuilder::SubtractFromVisibleRegion r=gregp,tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D219211
2024-08-15 10:14:18 +00:00
Jonathan Kew b013332b32 Bug 1910153 - Support non-sRGB color interpolation when painting background gradient. r=gfx-reviewers,lsalzman,ahale
Differential Revision: https://phabricator.services.mozilla.com/D218392
2024-08-03 20:24:44 +00:00
Glenn Watson b43f241b00 Bug 1909933 - Fix backdrop-filter on a transformed + complex clip r=tnikkel
Ensure that when we construct a wrapping surface for a transform
due to a complex clip, we mark it as wrapping a backdrop-filter
when that is required.

Differential Revision: https://phabricator.services.mozilla.com/D217922
2024-07-29 22:57:16 +00:00
Ashley Hale cac93eda00 Bug 1896503 - Implement FilterInstance code to send SVG filter graph to WebRender r=mstange,gw
Differential Revision: https://phabricator.services.mozilla.com/D174208
2024-06-24 23:45:05 +00:00
aiunusov f31528cc43 Bug 1897400 - prepare TimeoutManager for reuse in workers via nsIGlobalObject, r=smaug
- methods IsBackgroundInternal(), IsRunningTimeout(), TimeoutManager() were moved to nsIGlobalObject

Differential Revision: https://phabricator.services.mozilla.com/D211008
2024-06-24 10:29:16 +00:00
Cristian Tuns 6d8d6c1f98 Backed out changeset f479ecc1133d (bug 1897400) for causing build bustages in TimeoutManager.cpp CLOSED TREE 2024-06-21 10:32:22 -04:00
aiunusov 25391ea7c1 Bug 1897400 - prepare TimeoutManager for reuse in workers via nsIGlobalObject, r=smaug
- methods IsBackgroundInternal(), IsRunningTimeout(), TimeoutManager() were moved to nsIGlobalObject

Differential Revision: https://phabricator.services.mozilla.com/D211008
2024-06-21 11:27:32 +00:00
Iulian Moraru 213305106a Backed out changeset c2eaf893e115 (bug 1896503) for causing webrender crashes. a=backout 2024-06-19 12:55:32 +03:00
Ashley Hale 43eb5ac0a7 Bug 1896503 - Implement FilterInstance code to send SVG filter graph to WebRender r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D174208
2024-06-18 07:02:34 +00:00
Norisz Fay d35b9171ef Backed out changeset 9ff43ea4a5c9 (bug 1896503) for causing reftest failures 2024-06-13 09:34:12 +03:00
Ashley Hale c72e7174f8 Bug 1896503 - Implement FilterInstance code to send SVG filter graph to WebRender r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D174208
2024-06-13 01:34:20 +00:00
Gregory Pappas 1facf5b86b Bug 1900879 - part 2: Remove unused PaintTracker r=layout-reviewers,TYLin
Depends on D212742

Differential Revision: https://phabricator.services.mozilla.com/D212743
2024-06-06 22:10:42 +00:00
Gregory Pappas 516e3e428a Bug 1900739 - Remove IsCompositingCheap() r=tnikkel
It's not used since bug 1726291

Differential Revision: https://phabricator.services.mozilla.com/D212649
2024-06-05 10:03:52 +00:00
Otto Länd 8b065c2f1c Bug 1896516: apply code formatting via Lando
# ignore-this-changeset
2024-05-30 06:36:30 +00:00
Ting-Yu Lin 1e80f659a2 Bug 1896516 Part 11 - Remove nsIScrollableFrame usages under layout/, widget/, and toolkit/. r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211498
2024-05-30 06:32:22 +00:00
Ting-Yu Lin f390af5424 Bug 1896516 Part 10 - Remove nsIScrollableFrame usages under gfx/. r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211497
2024-05-30 06:32:21 +00:00
Ting-Yu Lin 6306934820 Bug 1896516 Part 7 - Remove PresShell::GetRootScrollFrameAsScrollable(). r=layout-reviewers,emilio
`PresShell::GetRootScrollFrameAsScrollable()` is equivalent to
`PresShell::GetRootScrollContainerFrame()`.

In ScrollContainerFrame.h, `DecideScrollableLayer()` has two versions, one has
four parameters, and the other has five parameters with the fifth parameter
`aDirtyRectHasBeenOverriden` having a default value `nullptr`. When we switch
the caller from `nsIScrollableFrame` to `ScrollContainerFrame`, we need to
remove the default value for the fifth parameter to avoid ambiguity.

Differential Revision: https://phabricator.services.mozilla.com/D211494
2024-05-30 06:32:20 +00:00
Ting-Yu Lin df8ff2d9ac Bug 1896516 Part 3 - Change GetScrollTargetFrame() to return ScrollContainerFrame. r=layout-reviewers,emilio
Also, simplify some callers of `GetScrollTargetFrame()` to drop
`nsIScrollableFrame*` and unnecessary `do_QueryFrame`. We'll continue removing
more `nsIScrollableFrame*` in later parts.

Differential Revision: https://phabricator.services.mozilla.com/D211490
2024-05-30 06:32:18 +00:00
Ting-Yu Lin f13f5fc5d4 Bug 1896516 Part 1 - Rename PresShell::GetRootScrollFrame(), and make it return ScrollContainerFrame. r=layout-reviewers,emilio
In theory, changing the return type from `nsIFrame*` to `ScrollContainerFrame*`
exposes `ScrollContainerFrame` to the callers who might not needed, but almost
all of the callers in cpp files are already exposed to `nsIScrollableFrame`, as
demonstrated in this patch via replacing the #include from
"nsIScrollableFrame.h" to "ScrollContainerFrame.h", so this is OK.

Some callers can be simplified since we no longer need `do_QueryFrame` to
`nsIScrollableFrame`.

Differential Revision: https://phabricator.services.mozilla.com/D211488
2024-05-30 06:32:17 +00:00
Jonathan Kew b3d36fba68 Bug 1896076 - patch 2 - Support passing both a local destination name and a URI when generating a hyperlink. r=gfx-reviewers,lsalzman
To take advantage of the new cairo capability, extend the link APIs to support
passing both a local destination name and a URI from the display list to the
rendering backend.

With this change, links to parts of the document that aren't included in the
print-to-pdf output will point back to the online resource, instead of just being
dead links.

(Note that this won't work the same on macOS at present, as we don't use
the cairo pdf backend there.)

Differential Revision: https://phabricator.services.mozilla.com/D211995
2024-05-29 17:19:38 +00:00
Sebastian Hengst ccb101be8f Backed out 15 changesets (bug 1896516) for causing scrolling crashes on macOS. a=backout
Backed out changeset fd6904338812 (bug 1896516)
Backed out changeset 2977ff81a23e (bug 1896516)
Backed out changeset c8a6b0e526d6 (bug 1896516)
Backed out changeset 3c06f22da72b (bug 1896516)
Backed out changeset f63b0c4335fe (bug 1896516)
Backed out changeset 6f7ab8adfa6e (bug 1896516)
Backed out changeset 997c9249dbed (bug 1896516)
Backed out changeset c964fccd5180 (bug 1896516)
Backed out changeset 7b481b747b7a (bug 1896516)
Backed out changeset 42e1bbe0ecb6 (bug 1896516)
Backed out changeset 717dac08b607 (bug 1896516)
Backed out changeset 2f0817331dbe (bug 1896516)
Backed out changeset b765169a7a8f (bug 1896516)
Backed out changeset a2d37b98273c (bug 1896516)
Backed out changeset ea9ecb543e66 (bug 1896516)
2024-05-29 11:22:52 +02:00
Otto Länd 0662f101d5 Bug 1896516: apply code formatting via Lando
# ignore-this-changeset
2024-05-28 04:59:10 +00:00
Ting-Yu Lin 6bd29e633d Bug 1896516 Part 11 - Remove nsIScrollableFrame usages under layout/, widget/, and toolkit/. r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211498
2024-05-28 04:46:20 +00:00
Ting-Yu Lin 2fa6b2e3d2 Bug 1896516 Part 10 - Remove nsIScrollableFrame usages under gfx/. r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211497
2024-05-28 04:46:20 +00:00
Ting-Yu Lin 9ab65dbb68 Bug 1896516 Part 7 - Remove PresShell::GetRootScrollFrameAsScrollable(). r=layout-reviewers,emilio
`PresShell::GetRootScrollFrameAsScrollable()` is equivalent to
`PresShell::GetRootScrollContainerFrame()`.

In ScrollContainerFrame.h, `DecideScrollableLayer()` has two versions, one has
four parameters, and the other has five parameters with the fifth parameter
`aDirtyRectHasBeenOverriden` having a default value `nullptr`. When we switch
the caller from `nsIScrollableFrame` to `ScrollContainerFrame`, we need to
remove the default value for the fifth parameter to avoid ambiguity.

Differential Revision: https://phabricator.services.mozilla.com/D211494
2024-05-28 04:46:19 +00:00
Ting-Yu Lin 9a9b18c0b6 Bug 1896516 Part 3 - Change GetScrollTargetFrame() to return ScrollContainerFrame. r=layout-reviewers,emilio
Also, simplify some callers of `GetScrollTargetFrame()` to drop
`nsIScrollableFrame*` and unnecessary `do_QueryFrame`. We'll continue removing
more `nsIScrollableFrame*` in later parts.

Differential Revision: https://phabricator.services.mozilla.com/D211490
2024-05-28 04:46:17 +00:00
Ting-Yu Lin 8dc0807324 Bug 1896516 Part 1 - Rename PresShell::GetRootScrollFrame(), and make it return ScrollContainerFrame. r=layout-reviewers,emilio
In theory, changing the return type from `nsIFrame*` to `ScrollContainerFrame*`
exposes `ScrollContainerFrame` to the callers who might not needed, but almost
all of the callers in cpp files are already exposed to `nsIScrollableFrame`, as
demonstrated in this patch via replacing the #include from
"nsIScrollableFrame.h" to "ScrollContainerFrame.h", so this is OK.

Some callers can be simplified since we no longer need `do_QueryFrame` to
`nsIScrollableFrame`.

Differential Revision: https://phabricator.services.mozilla.com/D211488
2024-05-28 04:46:16 +00:00
Olli Pettay b54796113c Bug 1897749 - Remove unused HadWillChange(), r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D210905
2024-05-20 12:29:23 +00:00
Ting-Yu Lin a9b5e69d86 Bug 1824877 Part 6 - Rename IsScrollContainer() to IsScrollContainerOrSubclass(). r=dholbert
This is to avoid confusion with `IsScrollContainerFrame()` introduced in Part 3.

A note to performance concern:

We've used `IsScrollContainerOrSubclass()` in bug 1873414 to avoid expensive
`nsIScrollableFrame* sf = do_QueryFrame()`. Per [1], casting from `nsIFrame*` to
`nsIScrollableFrame*` has no fast path.

Ideally, `ScrollContainerFrame* sf = do_QueryFrame()` should be fast, and we can
use it to implement `IsScrollContainerOrSubclass()` like
`IsImageFrameOrSubclass()`. However, in this patch, I intend to keep the
performance metrics unchanged.

Remove `GetAsScrollContainer()` since it's only used in `MOZ_ASSERT`, and I'm
planning to remove `nsIScrollableFrame` in bug 1896516.

[1] https://searchfox.org/mozilla-central/rev/dd6e430c1bc2db90d9b3b1dd7e5215b4edc4d51a/layout/generic/nsQueryFrame.h#117-121

Differential Revision: https://phabricator.services.mozilla.com/D210395
2024-05-15 17:50:50 +00:00
Ting-Yu Lin edb8e4ddd5 Bug 1824877 Part 3 - Change ScrollContainerFrame's type from Scroll to ScrollContainer. r=dholbert
This effectively changes the `IsScrollFrame()` helper to
`IsScrollContainerFrame()`.

Differential Revision: https://phabricator.services.mozilla.com/D210357
2024-05-15 17:50:49 +00:00
Timothy Nikkel 12991c6b74 Bug 1870415. In nsCanvasFrame::BuildDisplayList, only capture background items we create in our blend container item instead of any items that might be in the display list already. r=mstange,layout-reviewers,emilio
When we call nsCanvasFrame::BuildDisplayList from nsHTMLScrollFrame::BuildDisplayList there is already a compositor hit test item in it, created here https://searchfox.org/mozilla-central/rev/ff08e36e1f368bd193b54f569dbd79105b50f9a0/layout/generic/nsGfxScrollFrame.cpp#4146

If we create a blend container item in nsCanvasFrame::BuildDisplayList it puts everything that might already exist in the display list inside the blend container item. It should only do this for the background items that we just created as this is for background blend mode, we are only blending within the background of this frame.

In the fuzz testcase we then have a partial display list build that visits the root scroll frame (because a scroll bar is dirty), so it builds the compositor hit test item for the canvas frame (the child of the scroll frame), but canvas frame is not modified, so we don't descend into it, and we don't call nsCanvasFrame::BuildDisplayList, so the compositor hit test item does not get wrapped in the blend container, and thus it has moved in the display list without being marked modified.

Differential Revision: https://phabricator.services.mozilla.com/D209511
2024-05-06 21:11:33 +00:00
Botond Ballo 96b0a7307d Bug 1894555 - Run dynamic-toolbar-sticky-* tests on desktop as well. r=dlrobertson
Differential Revision: https://phabricator.services.mozilla.com/D209173
2024-05-04 03:14:31 +00:00
Narcis Beleuzu f96cae2fc8 Backed out changeset 49e49d8da627 (bug 1894555) for crashes on mochitest.toml . CLOSED TREE 2024-05-04 00:44:59 +03:00
Botond Ballo db26a769c7 Bug 1894555 - Run dynamic-toolbar-{fixed,sticky}-* tests on desktop as well. r=dlrobertson
Differential Revision: https://phabricator.services.mozilla.com/D209173
2024-05-03 19:36:41 +00:00
Botond Ballo 796ed84361 Bug 1874199 - Remove the workaround added in 1854010 to limit APZ animation of sticky elements to the root. r=dlrobertson
We still limit it to Android with dynamic toolbar enabled, which is
all we currently use it for.

Depends on D208238

Differential Revision: https://phabricator.services.mozilla.com/D208239
2024-05-02 02:49:22 +00:00
Dan Robertson 4486d95678 Bug 1874199 - Animate sticky elements by using an animation property on the StickyFrame rather than creating a ReferenceFrame. r=gw,dlrobertson
This uses the support added in the previous patch to set an animation property
on a StickyFrame spatial node directly.

Depends on D208237

Differential Revision: https://phabricator.services.mozilla.com/D208238
2024-05-02 02:49:21 +00:00
Botond Ballo b7116da08f Bug 1874199 - Add support for animation properties on StickyFrame spatial nodes. r=gw
The support is currently limited to translation transforms.

Depends on D208236

Differential Revision: https://phabricator.services.mozilla.com/D208237
2024-05-02 02:49:21 +00:00
pstanciu 06d741f4fa Backed out 4 changesets (bug 1874199) for causing WR bustages CLOSED TREE
Backed out changeset 0367fe61d2c9 (bug 1874199)
Backed out changeset 00d4835ec154 (bug 1874199)
Backed out changeset 4c6a338c5c30 (bug 1874199)
Backed out changeset 9756d029484d (bug 1874199)
2024-05-02 04:30:55 +03:00
Botond Ballo 9a17098d82 Bug 1874199 - Remove the workaround added in 1854010 to limit APZ animation of sticky elements to the root. r=dlrobertson
We still limit it to Android with dynamic toolbar enabled, which is
all we currently use it for.

Depends on D208238

Differential Revision: https://phabricator.services.mozilla.com/D208239
2024-05-02 00:14:02 +00:00