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

2856 Коммитов

Автор SHA1 Сообщение Дата
Emilio Cobos Álvarez 1ce0975b8e Bug 1761493 - Make Gecko internally consistent wrt what a link is. r=smaug
This is mostly edge-casey, but see bug 1757156 for an example where it's
causing some issues (granted, they could use `href="#"` or something
instead of an empty href).

It feels weird if a link looks like a link (because the CSS definition
of a link matches, which is "has an href") but then mostly doesn't
behave as a link.

We can't navigate anywhere if we don't have a valid URI but maybe JS
handles the relevant events as in bug 1757156.

Use the CSS definition (has href) since that's interoperable across
browsers. This should also make some stuff much faster (since checking
'is link' is now just a bit check instead of a virtual call).

(Awaiting try results, if no tests need adjustments then I need to write
some)

Differential Revision: https://phabricator.services.mozilla.com/D142107
2022-03-30 17:34:31 +00:00
Nicolas Silva ee545aca41 Bug 1761770 - Adjust item activity decisions. r=jrmuizel
Instead of reasoning about whether items should be active with a yes/no granularity, we consider whether it could/should be and have some logic to weight that against the risk of causing extra layerization when making containers active.
For example a small image *could* be made active, but we might not make it so if it causes extra layerization in cases where larger images would have been made active.

Differential Revision: https://phabricator.services.mozilla.com/D142213
2022-03-29 13:34:28 +00:00
David Shin 093b63fe3c Bug 1755770 - Ensure `TextRenderedRun::GetRunUserSpaceRect` casts float to int without invoking Undefined Behavior r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D142223
2022-03-28 21:07:58 +00:00
Hiroyuki Ikezoe 25d4e998dd Bug 1760222 - Ignore unchanged property for scroll-linked effect detector. r=hiro
I think this is cleaner.

Differential Revision: https://phabricator.services.mozilla.com/D141737
2022-03-27 23:40:24 +00:00
Miko Mynttinen f617868c63 Bug 1736069 - Unconditionally create nsDisplayStickyPosition items r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D141925
2022-03-24 17:40:32 +00:00
Cristian Tuns f0ccbd470c Backed out 4 changesets (bug 1760222) for causing reftest failures on disable-apz-for-sle-pages.html CLOSED TREE
Backed out changeset 1bf5e1ca3746 (bug 1760222)
Backed out changeset aff6bf37365d (bug 1760222)
Backed out changeset e9b3e3f52aec (bug 1760222)
Backed out changeset f65d2d719277 (bug 1760222)
2022-03-24 02:36:42 -04:00
Hiroyuki Ikezoe da3af8126d Bug 1760222 - Ignore unchanged property for scroll-linked effect detector. r=hiro
I think this is cleaner.

Differential Revision: https://phabricator.services.mozilla.com/D141737
2022-03-24 02:20:46 +00:00
Miko Mynttinen 93cb39c8cf Bug 1760847 - Deallocate linked list nodes when RemoveBottom() is called r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D141789
2022-03-22 22:34:37 +00:00
Emilio Cobos Álvarez 377390cc8a Bug 1759919 - Don't stop looking for intersecting frames too early in case there are fully-opaque transformed elements. r=miko,mconley
nsDisplayTransform::HitTest clips the rect it passes to its children,
and thus intersecting the whole area isn't relevant.

Depends on D141300

Differential Revision: https://phabricator.services.mozilla.com/D141301
2022-03-17 15:37:31 +00:00
Emilio Cobos Álvarez 1d365913dc Bug 1759749 - Avoid heap-allocating a rect property for most common outline case. r=dholbert
Now that we don't include overflow in outlines (bug 1739894) the
overwhelmingly common case is that innerRect == GetRectRelativeToSelf(),
except on a couple special cases.

Avoid storing the property in those cases. The test introduced in the
patch above still ensures we invalidate rendering correctly even without
the presence of the assert.

Depends on D141320

Differential Revision: https://phabricator.services.mozilla.com/D141321
2022-03-17 12:16:16 +00:00
Jeff Muizelaar 3c891365f9 Bug 1759953 - Remove useless condition in SetBuildingRect. r=emilio
Previously this condition avoided setting mPaintRectValid = false
but that's no longer here.

Differential Revision: https://phabricator.services.mozilla.com/D141313
2022-03-17 01:52:53 +00:00
Tooru Fujisawa d3c9c2abef Bug 1752624 - Skip drawing border if the dirty rect and the border rect do not intersect. r=miko
Differential Revision: https://phabricator.services.mozilla.com/D141104
2022-03-15 18:36:04 +00:00
Marian-Vasile Laza 21901659f3 Backed out changeset bf5828257d6e (bug 1752624) for causing reftest failures on caret_on_presshell_reinit-2.html. 2022-03-15 15:18:40 -07:00
Tooru Fujisawa 3581ab34d1 Bug 1752624 - Skip drawing border if the dirty rect and the border rect do not intersect. r=miko
Differential Revision: https://phabricator.services.mozilla.com/D141104
2022-03-15 18:36:04 +00:00
Miko Mynttinen 328ebe09e8 Bug 1744069 - Restore the previous behavior of merging RDL list traversal r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D140920
2022-03-14 15:11:05 +00:00
Miko Mynttinen ed38473dcc Bug 1757184 - Allocate display list nodes from nsPresArena instead of ArenaAllocator r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D139863
2022-02-28 19:16:04 +00:00
Emilio Cobos Álvarez 384bfcf2b6 Bug 1757230 - Avoid unneeded includes in nsTextFrame.h. r=longsonr
Move stuff to the C++ file where possible, and move ClipEdges to
nsTextFrame since it's the only thing using it (rather than keeping it
in nsDisplayText).

Also avoids a RemoteBrowser.h include from nsDisplayList.h while at it.

This came up in https://phabricator.services.mozilla.com/D137271#inline-768125

Differential Revision: https://phabricator.services.mozilla.com/D139759
2022-02-25 22:18:11 +00:00
Jeff Muizelaar ee8edce30e Bug 1755975 - Pass rect or path directly to Clip() instead of manually creating a path. r=gfx-reviewers,mstange
Differential Revision: https://phabricator.services.mozilla.com/D139038
2022-02-24 14:42:35 +00:00
Nicolas Silva 50ca258be2 Bug 1755747 - Add support for antialiased non-snapped rectangles. r=gfx-reviewers,aosmond
We need them for SVG primitives.

This patch adds a bit of plumbing to disable snapping some of the primitives and forcing the antialiasing shader feature where needed, and uses it for SVG solid rectangles and images.

Differential Revision: https://phabricator.services.mozilla.com/D139024
2022-02-23 13:37:39 +00:00
Miko Mynttinen 3b372336d7 Bug 1714584 - Part 3: Add crashtest r=nical
Depends on D138153

Differential Revision: https://phabricator.services.mozilla.com/D139428
2022-02-22 23:42:18 +00:00
Miko Mynttinen 017d02d0ff Bug 1714584 - Part 2: Remove nsDisplayList::RemoveBottom() r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D138153
2022-02-22 23:42:18 +00:00
Miko Mynttinen ddec6eef59 Bug 1714584 - Part 1: Decouple nsDisplayList internal list from nsDisplayItems r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D138152
2022-02-22 23:42:18 +00:00
Norisz Fay 2121660ce9 Backed out 2 changesets (bug 1714584) per devs request for causing crashes a=backout
Backed out changeset 3baead3e079b (bug 1714584)
Backed out changeset a2da895a58ce (bug 1714584)
2022-02-22 16:41:57 +02:00
Miko Mynttinen 0bd7fc8c56 Bug 1714584 - Part 2: Remove nsDisplayList::RemoveBottom() r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D138153
2022-02-22 00:44:25 +00:00
Miko Mynttinen 28474c7ad2 Bug 1714584 - Part 1: Decouple nsDisplayList internal list from nsDisplayItems r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D138152
2022-02-22 00:44:25 +00:00
Nicolas Silva 4824b5ed95 Bug 1753404 - Avoid extra blob tiles from invisible items. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D137862
2022-02-21 21:57:03 +00:00
Miko Mynttinen ad4c9a454d Bug 1722346 - Only append to the end/top of the display list r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D137894
2022-02-21 16:50:22 +00:00
Norisz Fay f0dc70995f Backed out changeset f06972b41abe (bug 1755975) for causing multiple reftest failures CLOSED TREE 2022-02-18 04:04:47 +02:00
Jeff Muizelaar b2aca21424 Bug 1755988 - Switch back to CreateSimilarDrawTarget for luminance masking. r=gfx-reviewers,aosmond
Bug 1285857 changed from using CreateSimilarDrawTarget on D2D to using a
software DrawTarget because of the need to convert the result to
luminance. However, after that bug 1417903 changed the luminance
conversion to use the IntoLuminanceSource which is supported directly by
D2D which removed the need for a software DrawTarget.

This will let us use a recording DrawTarget which will avoid serializing
the image data and is step toward switching to CreateClippedDrawTarget.

Differential Revision: https://phabricator.services.mozilla.com/D139046
2022-02-17 20:27:16 +00:00
Jeff Muizelaar 0cfa7fdb40 Bug 1755975 - Pass rect or path directly to Clip() instead of manually creating a path. r=gfx-reviewers,mstange
Differential Revision: https://phabricator.services.mozilla.com/D139038
2022-02-17 20:24:38 +00:00
Emilio Cobos Álvarez 4a152fdf3e Bug 1746248 - Style system and plumbing for mix-blend-mode: plus-lighter. r=jrmuizel,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D137951
2022-02-09 03:15:52 +00:00
Daniel Holbert cdc5972bff Bug 1754315: Fix non-unified build errors in layout/painting, and mark it as safe to build in non-unified mode. r=boris
Build errors fixed here:

layout/painting/DottedCornerFinder.cpp:33:1: error: no template named 'nsTHashMap'
(and similar for layout/painting/DashedCornerFinder.cpp)

* Fixed by including nsTHashMap.h

layout/painting/WindowRenderer.cpp:186:38: error: use of undeclared identifier 'Rect'; did you mean 'gfx::Rect'?
layout/painting/WindowRenderer.cpp:111:18: error: unknown type name 'PersistentBufferProvider'; did you mean 'layers::PersistentBufferProvider'?
(and more similar errors for e.g. `PersistentBufferProviderBasic::Create`, etc.)

* Fixed by adding 'using' statements.

layout/painting/WindowRenderer.cpp:117:8: error: use of undeclared identifier 'gfxPlatform'
layout/painting/WindowRenderer.cpp:148:57: error: member access into incomplete type 'mozilla::dom::AnimationEffect'
layout/painting/WindowRenderer.cpp:150:16: error: incomplete type 'mozilla::EffectSet' named in nested name specifier
layout/painting/WindowRenderer.cpp:211:26: error: member access into incomplete type 'mozilla::nsDisplayList'

* Fixed by including these types' headers.

layout/painting/HitTestInfo.cpp:67:32: error: use of undeclared identifier 'CompositorHitTestFlags'; did you mean 'gfx::CompositorHitTestFlags'?

* Fixed by adding 'using' statement.

layout/painting/nsCSSRenderingGradients.cpp:772:26: error: incomplete type 'nsLayoutUtils' named in nested name specifier

* Fixed by including nsLayoutUtils.h

layout/painting/nsCSSRenderingGradients.h:106:29: error: unknown type name 'gfxPattern'

* Fixed with a forward-decl.

layout/painting/nsCSSRenderingGradients.h:107:30: error: unknown type name 'gfxRect'

* Fixed with an include (can't use a forward-decl here; gfxRect is a typedef and hence can't really be forward-declared).

Differential Revision: https://phabricator.services.mozilla.com/D138219
2022-02-09 01:06:29 +00:00
Jeff Muizelaar d10642bdfd Bug 1753719 - Properly convert the result of GetMaskArea to device pixels. r=dholbert
Previously, we would get the wrong bounds on HiDPI displays.
This matches what's done in ComputeClipForMaskItem and makes things a bit
more explicit by using typed units.

Differential Revision: https://phabricator.services.mozilla.com/D137880
2022-02-07 22:01:35 +00:00
Emilio Cobos Álvarez 81272b8d66 Bug 1753453 - Remove unused nsImageRenderer::IsAnimatedImage. r=aosmond
Drive-by cleanup.

Depends on D137762

Differential Revision: https://phabricator.services.mozilla.com/D137764
2022-02-03 17:31:41 +00:00
Nicolas Silva 89a8f2b82c Bug 1753442 - Add a pref to ignore will-change:opacity. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D137755
2022-02-03 15:48:33 +00:00
Brad Werth b0c4fa2839 Bug 1723469 Part 1: Prevent large background images from using opacity flattening. r=aosmond,emilio
This prevents opacity from being set on large images sent to WebRender.
Instead, opacity will be handled in the parent layer, which is less efficient,
but correct for these large images.

This can be a temporary fix until WR supports opacity on arbitrarily large
images.

Differential Revision: https://phabricator.services.mozilla.com/D137360
2022-02-01 17:29:34 +00:00
Andi-Bogdan Postelnicu 30631a4a9b Bug 1519636 - Reformat recent changes to the Google coding style. r=sylvestre
Updated with clang-format version 13.0.0 (taskcluster-dIIauZE0TkuXy6_23BQhcw)

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D137147
2022-01-31 17:00:21 +00:00
Daniel Holbert 93a7663777 Bug 1740304: Apply the print fragmentation-fallback "additional offset" in one case where it was being missed. r=miko
We call MaybeApplyAdditionalOffset a few lines up when setting *aOffset, but it
looks like we missed this particular codepath.  This was causing content to
render properly during print-preview (which takes the upper codepath) but not
during actual printing (which takes the lower codepath, the one where I'm
adding the new call).

Differential Revision: https://phabricator.services.mozilla.com/D137199
2022-01-29 00:50:17 +00:00
Miko Mynttinen 2175f47f8f Bug 1751965 - Remove destroyed display items from reused display items list r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D137235
2022-01-28 16:30:55 +00:00
Timothy Nikkel 0661a47e1c Bug 1751806. Remove active content tracking from ActiveLayerTracker as it is unused. r=mstange
Depends on D136816

Differential Revision: https://phabricator.services.mozilla.com/D136817
2022-01-26 11:39:13 +00:00
Timothy Nikkel 2933d9ccc7 Bug 1751806. Remove background position and offset tracking from ActiveLayerManager as they are unused. r=mstange
Depends on D136815

Differential Revision: https://phabricator.services.mozilla.com/D136816
2022-01-26 11:39:13 +00:00
Timothy Nikkel d1a54b0a05 Bug 1751806. Remove usage of gfxVars::UseWebRender in ActiveLayerTracker which is always true. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D136815
2022-01-26 11:39:12 +00:00
Miko Mynttinen 47e3664850 Bug 1751743 - Add missing ifdef r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D136824
2022-01-25 13:08:51 +00:00
Timothy Nikkel 24844705a8 Bug 1750850. Remove the code that tracks "active layers" from changes made in scroll handlers. r=mstange
This was added in bug 1201330 but with WR isn't really needed anymore and the code causes the expiration timer to fire until the scroll frame becomes inactive (the most common scroll frames stay active, ie root scroll frames).

Differential Revision: https://phabricator.services.mozilla.com/D136806
2022-01-24 23:39:07 +00:00
Miko Mynttinen 978b3d9089 Bug 1697979 - Part 1: Reuse previously built stacking context display items without merging r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D128413
2022-01-22 02:37:31 +00:00
Alexandru Michis ae4456b8b6 Backed out 3 changesets (bug 1697979) for causing reftest failures in retained-dl-displayport-1.html
Backed out changeset e4248d811360 (bug 1697979)
Backed out changeset db3882cc536c (bug 1697979)
Backed out changeset ea7ce38abaab (bug 1697979)
2022-01-21 04:01:27 +02:00
Miko Mynttinen 07449db71e Bug 1697979 - Part 1: Reuse previously built stacking context display items without merging r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D128413
2022-01-21 00:43:34 +00:00
Noemi Erli 2bfdec7254 Backed out 3 changesets (bug 1697979) for causing reftest failures CLOSED TREE
Backed out changeset 4edb10a45d13 (bug 1697979)
Backed out changeset 456b57492294 (bug 1697979)
Backed out changeset 1cb3b14f2f6c (bug 1697979)
2022-01-20 22:25:00 +02:00
Miko Mynttinen 3882f995d9 Bug 1697979 - Part 1: Reuse previously built stacking context display items without merging r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D128413
2022-01-20 18:38:59 +00:00
Miko Mynttinen c1b142f453 Bug 1751018 - Change FrameFlags to EnumSet r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D136392
2022-01-20 00:21:15 +00:00