Commit Graph

896 Commits

Author SHA1 Message Date
Kartikaya Gupta
26f0373ad0 Bug 1389149 - Extract the logic from nsDisplayLayerEventRegions::AddFrame into a more reusable form. r=mstange
This introduces a enum bitset type that encapsulates some of the
interesting properties that frames have that make it interesting for
hit-testing in the compositor. This type is designed so it can be sent
directly to webrender and gotten back in the hit-test.

MozReview-Commit-ID: GCxV7ZaoJd1

--HG--
extra : rebase_source : a9cc5ecfc7c5baeab2f6e08cd2ee2c2a7756e20c
2017-11-15 11:39:44 -05:00
Gurzau Raul
f464825286 Merge mozilla-central to mozilla-autoland. r=merge a=merge CLOSED TREE 2017-11-16 12:16:07 +02:00
Gurzau Raul
6dcee027d7 Merge inbound to mozilla-central r=merge a=merge 2017-11-16 12:04:45 +02:00
Narcis Beleuzu
af710e4746 Backed out changeset 0f783930e1b2 (bug 1406727) for GTest failures on ArenaAllocator. r=backout on a CLOSED TREE 2017-11-16 07:45:06 +02:00
Matt Woodrow
5e1a10f3be Bug 1406727. r=froydnj 2017-11-16 16:09:28 +13:00
Matt Woodrow
12d7cfd60d Bug 1416291 - Don't do partial display list building within preserve-3d contexts. r=miko 2017-11-16 16:09:19 +13:00
peter chang
8d32c73914 Bug 1410334 - Create correct animation properties based on WrAnimationProperty info, r=kats
MozReview-Commit-ID: 6LNbwQd9IfX

--HG--
extra : rebase_source : 2b53786ae996237bef7bf8100087b3f48667d718
2017-11-15 16:09:21 +08:00
Ethan Lin
90f209e713 Bug 1415407 - Add webrender support for filters (hue-rotate, opacity, saturate). r=kats
MozReview-Commit-ID: 7LGmFOsyPUU

--HG--
extra : rebase_source : 0c6716c8a2db602a7dcab39ed25975e107c3d5d2
2017-11-08 04:04:27 +00:00
Markus Stange
a25f1fafb3 Bug 1417197 - Create nsITheme::CreateWebRenderCommands in order to optimize simple theme fills, and add a Mac implementation. r=jrmuizel
MozReview-Commit-ID: 1G9NHPwd5ST

--HG--
extra : rebase_source : 74189f1bad32600979b099663bae27cd24d1f0ec
2017-11-14 15:34:56 -05:00
Markus Stange
457af832c8 Bug 1415203 - Don't refuse to create WebRender commands due to -moz-border-*-colors on border sides that don't have a border. r=jrmuizel
MozReview-Commit-ID: DPQQgds3GOk

--HG--
extra : rebase_source : 8fd44cb73619f475accd0ae5eb098b317cb958de
2017-11-14 15:47:53 -05:00
Sebastian Hengst
31bab6f683 Backed out changeset 32958aa32cb5 (bug 1415485) for frequently failing for failing reftest layout/reftests/async-scrolling/position-fixed-in-scroll-container.html on Linux x64 QuantumRender. r=backout a=backout on a CLOSED TREE 2017-11-14 14:47:14 +02:00
Miko Mynttinen
b7715ba593 Bug 1415485 - Make the pref layout.display-list.retain live again r=mattwoodrow
MozReview-Commit-ID: 6QFc4Sq3WiC

--HG--
extra : rebase_source : 946f69b611544671556aaab66654d2e30c59b4ef
extra : intermediate-source : 7ee9657574a2ee223b6184d1657803a0d382be59
extra : source : 558439637eba09eaae8a653ffc77d5830b16ff42
2017-11-09 16:10:21 +01:00
Kartikaya Gupta
92c112278f Bug 1416540 - Convert a bunch of scaling code to avoid unnecessary double conversion. r=mattwoodrow
The code in ComputeSuitableScaleForAnimation feeds its double-based
computation results into GetSuitableScale, which takes and returns
floats. Also the double-based computation that it's doing involves
calling UpdateMinMaxScale a bunch which explicitly uses the float
variant of std::min and std::max. And all of this is used from
ChooseScaleAndSetTransform which does other things like call a
"RoundToFloatPrecision" function, and casts the final values to
floats before setting the layer's prescale. So let's just use
floats all the way through.

MozReview-Commit-ID: BE3WC5hv89d

--HG--
extra : rebase_source : 987d9d69ec2a200ed68c59bae5fae1115713a94c
2017-11-12 18:37:33 -05:00
Kartikaya Gupta
6fe3141125 Bug 1416540 - Avoid unnecessary conversion to doubles in ActiveLayerTracker code. r=mstange
This code was written before the ScaleFactors() function was available on
the float-based gfx::Matrix, which I presume is why it was written to
convert the matrix to the double-based variant and store the scale as
doubles. We don't need to do that any more.

MozReview-Commit-ID: EoWLpny8g61

--HG--
extra : rebase_source : 4cac59121961bfb35359def042ac4b0200a85312
2017-11-12 18:37:33 -05:00
Kartikaya Gupta
2c46265720 Bug 1416540 - Avoid unnecessary use of double-based types in GenerateAndPushTextMask. r=jfkthame
The code here feeds into gfxContext::mTransform which is float-based, so
using double-based rects and matrices here is unnecessary.

MozReview-Commit-ID: CbeMM8003DA

--HG--
extra : rebase_source : 735d5c880cca36b9e9bea6cb0c94825b6a1c4597
2017-11-12 18:37:32 -05:00
Matt Woodrow
3af1439f69 Bug 1416448 - Don't update the ASR during merging for an empty container item, since we can't compute the ASR of the contents. r=miko 2017-11-13 09:02:48 +13:00
Matt Woodrow
53892cd491 Bug 1413073 - Fix rebase issue that caused us to only update the container asr for reused items. 2017-11-11 15:46:48 +13:00
Ethan Lin
beaea27dc3 Bug 1415989 - Do not use 'ShouldUseAdvancedLayer' for button type display items. r=jrmuizel
MozReview-Commit-ID: 83qOTfTRUY0

--HG--
extra : rebase_source : 560f285f3092cd75d14d27cae4adcb8e9dca0e3a
2017-11-10 11:41:15 +08:00
Kartikaya Gupta
00ef028ed3 Bug 1416267 - Update gfxContext matrix functions to avoid flip-flopping between float and double matrices. r=jrmuizel
The core of this change is in gfxContext.*:
- change gfxContext::CurrentMatrix() and gfxContext::SetMatrix() to
  return and take a Matrix respectively, instead of converting to
  and from a gfxMatrix (which uses doubles). These functions therefore
  will now match the native representation of the transform in gfxContext.
- add two new functions CurrentMatrixDouble() and SetMatrixDouble() that
  do what the old CurrentMatrix() and SetMatrix() used to do, i.e.
  convert between the float matrix and the double matrix.

The rest of the change is just updating the call sites to avoid round-
tripping between floats and doubles where possible. Call sites that are
hard to fix are migrated to the new XXXDouble functions which preserves
the existing behaviour.

MozReview-Commit-ID: 5sbBpLUus3U
2017-11-10 21:14:09 -05:00
Miko Mynttinen
c94a72556d Bug 1416065 - Ensure that override dirty rects are properly removed from frames r=mattwoodrow
MozReview-Commit-ID: 8uLgDFxl5MV

--HG--
extra : rebase_source : f8b1202e068b448499ebe470c9d9151715cb1419
2017-11-10 01:32:29 +01:00
Noemi Erli
8d8df3ddfe Merge mozilla-central to mozilla-autoland. r=merge a=merge CLOSED TREE 2017-11-10 12:43:53 +02:00
Matt Woodrow
1696dda8f9 Bug 1413073 - Part 3: Recompute ASR and clip-chains on wrap lists when merging. r=mstange
--HG--
extra : rebase_source : 5c03d88f8d3467dad32fc3589803180fdad4e488
2017-11-10 13:16:55 +13:00
Matt Woodrow
7e5b5d152d Bug 1413073 - Part 2: Only force frames to have display items built if they intersect the dirty rectangle. r=mstange
--HG--
extra : rebase_source : d26f57488cb298cb3d1ea0b3ca600925279a5976
2017-11-10 13:16:45 +13:00
Matt Woodrow
367e79bd4d Bug 1413073 - Part 1: Add new crashtests for complex ASR cases. r=mstange
--HG--
extra : rebase_source : b2a075e9c703d7cd470546cf2bbd6516bea8192f
2017-11-10 13:16:36 +13:00
Matt Woodrow
e1ee7ce3d0 Bug 1415672 - Don't invalidate the entire frame tree when we're marking a specific frame as being modified. r=miko
--HG--
extra : rebase_source : 7ec5936718e52803bcdf6f1edf435b8247c5107d
2017-11-10 13:16:26 +13:00
Kartikaya Gupta
33e88b3fce Bug 1416067 - Avoid doing a bunch of useless event-regions work for frames with empty border boxes. r=mstange
MozReview-Commit-ID: 8gsIJojhQ6t

--HG--
extra : rebase_source : 74689a0a32e1406e02de8b46e0e12d6ffdc2aeb0
2017-11-09 19:40:44 -05:00
Kartikaya Gupta
463cce7a87 Bug 1415225 - Small early-exit optimization. r=botond
MozReview-Commit-ID: A3UuqKKOsjA

--HG--
extra : rebase_source : 78042095524bda3371f347817b2ff201c9863729
2017-11-09 09:03:52 -05:00
Kartikaya Gupta
93ca1a3bc5 Bug 1415225 - Stop setting the EventRegionsOverride flag on root layers. r=botond,mattwoodrow
As with the previous patch, instead of setting the override on the root
layer, we set the flag on the nsDisplayListBuilder before building the
display list, and the flag automatically forces all event regions
display items to use their dispatch-to-content region instead of any
other regions.

Both the WebRender and non-WebRender codepaths were setting the override
flag on their root layers and don't need to any more.

MozReview-Commit-ID: 1cz0ahqwkOm

--HG--
extra : rebase_source : 3292951aca97fd1a355c2fae5b0ab42d2064c548
2017-11-09 09:03:52 -05:00
Kartikaya Gupta
028fa48259 Bug 1415225 - Stop setting the EventRegionsOverride flag on in-process subdocument layers. r=botond
The mechanics of this change is fairly straightforward - instead of setting the
override on the layer corresponding to the in-process subdocument, we just set
the flag on the display list builder; that flag is already checked when building
the layer event regions for descendant nsIFrames.

As a side-effect, we also don't need to force a layer for in-process subdocuments
just because they have document-level APZ-aware listeners. One of reasons we were
doing so before was so that we would have a layer to stash the override flags on
but now we don't need that any more.

Note that out-of-process subdocuments are not affected; for those cases
the nsSubDocumentFrame delegates BuildDisplayList to
RenderFrameParent/nsDisplayRemote, which will still set the overrides on
the RefLayer that is created.

MozReview-Commit-ID: DZWglE4e62p

--HG--
extra : rebase_source : 78494a5cbfd0dfecb5f2262e5c1b3dc5367c5d55
2017-11-09 09:03:51 -05:00
Sebastian Hengst
1b0413a887 merge mozilla-inbound to mozilla-central. r=merge a=merge 2017-11-09 11:53:05 +02:00
Miko Mynttinen
845735af56 Bug 1395476 - Do not call mStoredList.RecomputeVisibility for 3d transforms r=mattwoodrow
MozReview-Commit-ID: 1pnYL2RtFi6

--HG--
extra : rebase_source : 85699125c4b547b99ce2bf8580e0cd40720a285b
2017-11-08 02:54:10 +01:00
Mats Palmgren
770a2228d1 Bug 1414666 part 2 - A few formatting improvements after mass conversion of PresContext()->PresShell() to PresShell(). r=emilio
MozReview-Commit-ID: FoEnINS0Jbk
2017-11-09 03:00:48 +01:00
Mats Palmgren
1c2b8c222e Bug 1414666 part 1 - Add nsIFrame::PresShell() for convenient access to the shell. r=emilio
MozReview-Commit-ID: 8FPTPKWyVtY
2017-11-09 03:00:48 +01:00
Narcis Beleuzu
218e1676cb Merge inbound to mozilla-central r=merge a=merge 2017-11-08 12:51:09 +02:00
Matt Woodrow
cd1604ef74 Bug 1414397 - Make sure we properly invalidate the entire frame subtree when detecting a caret frame change. r=miko
--HG--
extra : rebase_source : add63296c95ea090ca79ab120bede8038ce4f59e
2017-11-08 15:33:34 +13:00
Matt Woodrow
fca4960b0f Bug 1412110 - Make sure we build a wrap list for the caret frame, since it will have multiple display items. r=miko
--HG--
extra : rebase_source : b59ff089835023c96daa1e1bf1c7f5bde6c75f15
2017-11-08 15:32:27 +13:00
Matt Woodrow
0cd1c74fe2 Bug 1413833 - Don't use WeakFrame for the modified frame list since get slow with large numbers of frames. r=miko
--HG--
extra : rebase_source : c2c2f2c6435ad1b2f246d1339ee548dc60cec4b4
2017-11-08 15:25:44 +13:00
Coroiu Cristina
dc06fb21ec Merge mozilla-central to mozilla-autoland. r=merge a=merge on a CLOSED TREE 2017-11-07 01:13:57 +02:00
Manish Goregaokar
b5061541d9 Bug 1405881 - Add crashtest; r=hiro
MozReview-Commit-ID: BzM8KRn2MWv

--HG--
extra : rebase_source : 288825a0262a051ba379cdd74838c358f70901de
2017-11-06 11:30:49 -08:00
Manish Goregaokar
b8a28fb4e0 Bug 1405881 - Fix animation of -moz-transform matrices with percents ; r=hiro
MozReview-Commit-ID: 4XhKc0K0xmQ

--HG--
extra : rebase_source : 883fd587716a97d38827e576a8d1af808fa22f7e
2017-11-03 16:42:30 -07:00
Ethan Lin
0d2b959f9f Bug 1410583 - Make sure we paint the whole item for blob image. r=jrmuizel
MozReview-Commit-ID: 84LiyRA2WFC

--HG--
extra : rebase_source : 769128dff81e4610decf2fbe53196a94e7857773
2017-11-06 16:51:16 +08:00
Ethan Lin
f18aa8ed14 Bug 1413397 - Avoid empty border's fallback. r=kats
MozReview-Commit-ID: 1KXYjcObJdi

--HG--
extra : rebase_source : ea36d0f77dff76175dbc6d2a27cb0017e703e0bf
2017-11-01 17:30:04 +08:00
Kevin Chen
24e2b68f15 Bug 1409243 - Enable dotted and dashed border support for webrender; r=ethlin
MozReview-Commit-ID: 4TGeavMJY2Q

--HG--
extra : rebase_source : 1638dcf7abf66736e17b632fa2ae1f19bbe5e920
2017-10-25 10:17:41 +08:00
ANDREEA PAVEL
24a187da02 Merge mozilla-inbound to mozilla-central r=merge a=merge 2017-11-02 11:40:57 +02:00
Botond Ballo
864f4f712b Bug 1382534 - Use GetBounds() in nsDisplayMask::ComputeVisibility(). r=mstange
The code previously used GetClippedBoundsWithRespectToASR() (changed
in bug 1298218), but this violated the requirements of nsDisplayList::
ComputeVisibilityForSublist().

MozReview-Commit-ID: F9UVMvVKLAp

--HG--
extra : rebase_source : ec188650070d4e8de1b19395c3ed6f31e7d0e04f
2017-10-16 17:18:03 -04:00
Botond Ballo
6a7049b903 Bug 1382534 - Relax the requirement of having a clip with respect to an ASR for nsDisplayMask items. r=mstange
We allow an nsDisplayMask item to satisfy the requirement even it does not
itself have a clip, as long as its children have finite bounds with respect
to the ASR.

MozReview-Commit-ID: 8zKE0bguY38

--HG--
extra : rebase_source : 74baaea2647708d1cd024f9e6afd82508e95c74a
2017-09-25 19:15:23 -04:00
Botond Ballo
ce03fa59d0 Bug 1382534 - Move ComputeOffsetToUserSpace() from nsDisplayList.cpp to nsLayoutUtils. r=mstange
MozReview-Commit-ID: 8w9lDViJuAj

--HG--
extra : rebase_source : 4d9c47dd4f217471e743973d2f641a67dae509fe
2017-08-23 17:26:25 -04:00
Botond Ballo
4a2d5338c5 Bug 1382534 - Layerize active masks even with HWA disabled. r=mstange
MozReview-Commit-ID: 6lvOE3fGFAy

--HG--
extra : rebase_source : 86e4c07873890e14d57708f202d7c611635bf070
2017-08-09 16:25:19 -04:00
Sebastian Hengst
ca88e3c4c5 Merge mozilla-central to autoland. r=merge a=merge 2017-11-01 22:58:44 +01:00
Kartikaya Gupta
3c38110bd3 Bug 1406217 - Fix computation of scrollframe's offset to the reference frame. r=mstange
We need to get the offset across documents boundaries, since the scrollframe
might be inside a subdocument. In such cases we were previously computing
a (incorrect) zero offset for the scrollframe, which was throwing off the
margin for the sticky items inside the scrollframe.

MozReview-Commit-ID: AWeQ9ay2cmp

--HG--
extra : rebase_source : 7dd8eda26c482cc359042d79073740524efa792a
2017-10-31 09:04:04 -04:00