Commit Graph

28461 Commits

Author SHA1 Message Date
Andrew Osmond
6615a08c2c Bug 1401672 - Make display items for the same WebRenderBridgeParent/Child share the ImageKey for shared surfaces. r=jrmuizel 2017-11-15 14:31:13 -05:00
Noemi Erli
f24a75f9b7 Merge mozilla-central to mozilla-inbound. r=merge a=merge CLOSED TREE 2017-11-15 12:15:40 +02:00
Noemi Erli
550148ab69 Merge inbound to mozilla-central r=merge a=merge 2017-11-15 11:57:12 +02:00
Lee Salzman
29099d481c Bug 1416607 - error when Moz2DImageRenderer fails to create a NativeFontResource or UnscaledFont. r=jrmuizel
MozReview-Commit-ID: Jool723LUFX
2017-11-14 23:15:31 -05:00
Chris Peterson
768b96f58b Bug 1415470 - build: Enable VS2017 C5038 initializer list order warnings (like gcc -Wreorder). r=glandium
C5038 is a new warning in VS2017, similar to gcc and clang's -Wreorder, which is enabled by -Wall. We should enable C5038 so Windows developers can see these warnings locally instead of when gcc and clang fail with warnings-as-errors on Try.

https://blogs.msdn.microsoft.com/vcblog/2017/07/21/diagnostic-improvements-in-vs2017-15-3-0/

We need to suppress C5038 warnings from Windows Runtime Library header files (wrl.h) included in ANGLE and widget/windows:

z:\build\build\src\vs2017_15.4.2\SDK\Include\10.0.15063.0\winrt\wrl\wrappers\corewrappers.h(515): error C5038: data member 'Microsoft::WRL::Wrappers::Details::SyncLockWithStatusT<Microsoft::WRL::Wrappers::HandleTraits::SemaphoreTraits>::sync_' will be initialized after data member 'Microsoft::WRL::Wrappers::Details::SyncLockWithStatusT<Microsoft::WRL::Wrappers::HandleTraits::SemaphoreTraits>::status_'
...

And suppress C5038 warnings in upstream webrtc code:

media/webrtc/trunk/webrtc/modules/video_capture/windows/BaseFilter.cpp(176): error C5038: data member 'mozilla::media::BaseFilter::mClsId' will be initialized after data member 'mozilla::media::BaseFilter::mState'
media/webrtc/trunk/webrtc/modules/video_capture/windows/BasePin.cpp(169): error C5038: data member 'mozilla::media::BasePin::mFilter' will be initialized after data member 'mozilla::media::BasePin::mLock'
media/webrtc/trunk/webrtc/modules/video_capture/windows/BasePin.cpp(170): error C5038: data member 'mozilla::media::BasePin::mLock' will be initialized after data member 'mozilla::media::BasePin::mName'
media/webrtc/trunk/webrtc/modules/video_capture/windows/BasePin.cpp(172): error C5038: data member 'mozilla::media::BasePin::mDirection' will be initialized after data member 'mozilla::media::BasePin::mQualitySink'

MozReview-Commit-ID: BMDVkvQXNoq

--HG--
extra : rebase_source : 0d5ede9530d0d0750b8fffdc1cdfdc646ec8f22a
2017-11-07 19:52:10 -08:00
Lee Salzman
011e836339 Bug 1416607 - follow-up - typo fix in error message. r=me 2017-11-14 23:27:16 -05:00
Ethan Lin
8e57800f5a Bug 1416076 - We should set visible rect to display item before computing visibility. r=mattwoodrow
MozReview-Commit-ID: HngrLGSS6St

--HG--
extra : rebase_source : deac5b74dd8490a39c08f6944c359f27bc3cd7f9
2017-11-13 15:48:01 +08:00
Kevin Chen
49b2130100 Bug 1415469 - Remove mDeviceResetSequenceNumber from TDR process since we don't need it anymore; r=dvander
MozReview-Commit-ID: 3uQQwW8QOJA

--HG--
extra : rebase_source : ab6090ad51a2a4714f1739a30d854d624d187239
2017-11-08 15:26:43 +08: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
btara
986d32eb92 Merge mozilla-central to autoland r=merge a=merge on a CLOSED TREE 2017-11-14 22:40:50 +02:00
btara
d95e1d710b Merge inbound to mozilla-central r=merge a=merge 2017-11-14 22:37:02 +02:00
Ryan Hunt
0814b42b38 Only return a valid RotatedBuffer in ContentClientBasic::CreateBuffer (bug 1416790, r=dvander)
MozReview-Commit-ID: C5l4OHAWBLL

--HG--
extra : rebase_source : 720a4a458753cc27b9c2269b7da59e5712e47a22
2017-11-13 12:52:31 -05:00
Ryan Hunt
f881288e3b Don't use CompositorBridgeChild in PrepareBuffer if sync OMTP is enabled (bug 1416782, r=dvander)
MozReview-Commit-ID: DMbKcDEkkeP

--HG--
extra : rebase_source : 20608d09f18549816b10fd63d0879cfb409e8219
2017-11-13 12:51:19 -05:00
dluca
a662f122c3 Merge Inbound to mozilla-central r=merge a=merge 2017-11-14 16:56:05 +02: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
Sebastian Hengst
53f71049ff Backed out 2 changesets (bug 1416620) for failing own reftest. r=backout a=backout on a CLOSED TREE
Backed out changeset 3b45218edc2e (bug 1416620)
Backed out changeset c48580e1f535 (bug 1416620)
2017-11-14 13:04:52 +02:00
Coroiu Cristina
6a04305b5d Merge mozilla-central to inbound. r=merge a=merge on a CLOSED TREE 2017-11-14 12:31:45 +02:00
Nicolas Silva
7199975a93 Bug 1377595 - Don't use blob images for items that must be painted on the content side. r=kats 2017-11-10 13:44:58 +01:00
David Anderson
d177a5accc Fix bogus assert. (bug 1416369, r?=mattwoodrow) 2017-11-14 12:01:42 +02:00
Csoregi Natalia
8f1a81caad Merge inbound to mozilla-central r=merge a=merge 2017-11-14 00:57:47 +02:00
dluca
1904de3e5e Merge mozilla-central to Autoland r=merge a=merge on a CLOSED TREE 2017-11-14 17:00:43 +02:00
Sebastian Hengst
57fd5c3c24 merge mozilla-central to autoland. r=merge a=merge on a CLOSED TREE 2017-11-14 14:48:43 +02:00
Morris Tseng
78bddf84f9 Bug 1342762 - Remove pipeline in RemovePipelineIdForCompositable. r=nical
MozReview-Commit-ID: 29NrWHCGR5V

--HG--
extra : rebase_source : 25a4fc2f1abef15dbf5515516a45a34079acc8dd
2017-11-13 17:32:23 +08: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
Ting-Yu Lin
dfca359d6e Bug 1416699 - Add a space between #include and comment. r=jeremychen
Skip files under intl/icu/ because they're imported from third party.

DONTBUILD because this is a whitespace-only change.

MozReview-Commit-ID: GSd6oeFSTO7

--HG--
extra : rebase_source : 38c20bf6099c18b2fcb4c324d470b279addf8891
2017-11-13 17:54:18 +08:00
Ryan Hunt
c81dd046a2 Remove flush from RotatedBuffer::UpdateDestinationFrom (bug 1410919, r=nical)
MozReview-Commit-ID: AKuz0sUj8Jf

--HG--
extra : amend_source : 5021d2dbc5d1386205eb198379dd9c81550cf78c
2017-10-23 12:23:57 -04:00
Margareta Eliza Balazs
798dabeb2c Merge mozilla-central to mozilla-inbound. r=merge a=merge CLOSED TREE 2017-11-13 00:04:57 +02:00
shindli
0d157e6e2e Merge inbound to mozilla-central r=merge a=merge 2017-11-12 23:48:36 +02:00
JerryShih
9d834c457f Bug 1416543 - use the gecko profiler macro to register/unregister the thread name. r=me
MozReview-Commit-ID: 3ueSAuNCbGp
2017-11-12 22:21:22 +08:00
Coroiu Cristina
230207fe30 Merge inbound to mozilla-central r=merge a=merge 2017-11-12 00:05:11 +02:00
Jonathan Kew
49c97adb4e Bug 1411625 - Remove the constructor from gfxShapedText::CompressedGlyph to make it a trivial class, and provide a couple of convenience "factory" methods to create simple and complex glyph values. r=andi 2017-11-11 15:32:58 +00:00
JerryShih
c061f3959d Bug 1371838 - set the window_id as renderer_id to WR. r=jrmuizel
MozReview-Commit-ID: 7YbQNzTNpmE
2017-11-11 18:57:31 +08:00
JerryShih
4eb77c1992 Bug 1371838 - add a custom thread listener to WR. r=jrmuizel
MozReview-Commit-ID: yyFwBr21F3
2017-11-11 18:57:31 +08:00
JerryShih
56d6261465 Bug 1371838 - register the WR thread pool's thread to gecko profiler. r=jrmuizel
MozReview-Commit-ID: BUyTq2vz3cO
2017-11-11 18:57:31 +08:00
JerryShih
8b031732c0 Bug 1371838 - export the gecko profiler registering function to WR. r=jrmuizel
MozReview-Commit-ID: 2gVAmU2xomP
2017-11-11 18:57:31 +08:00
Andreea Pavel
7fb4cc447c Merge inbound to mozilla-central r=merge a=merge 2017-11-11 11:59:20 +02:00
Jonathan Kew
8de8fef958 Bug 1412090 - patch 4 - Also adopt the ContentParent::NotifyUpdatedFonts method on macOS, so that only the parent process needs to register with CFNotificationCenter for font-changed notifications. r=lsalzman 2017-11-09 16:54:37 +00:00
Jonathan Kew
d3412dc6b0 Bug 1412090 - patch 3 - Check the sandbox policy to verify font files will be readable by the content process before including them in the system font list. r=gps 2017-11-09 16:54:30 +00:00
Jonathan Kew
fe4d2e8b97 Bug 1412090 - patch 2.1 - Work around FcNameParse bug in fontconfig versions around 2.11.0, by escaping any leading space in the encoded charset element. r=lsalzman 2017-11-12 21:35:25 +00:00
Chih-Yi Leu
80c342950f Bug 1412554 - Return GL_OOM if memory counter in ResourceManager11 overflow r=jgilbert
MozReview-Commit-ID: AgDd95NlNZq

--HG--
extra : rebase_source : 8e5818d186aa151f9ba0cb1a6569de8f9211b049
2017-11-08 10:36:18 +08: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
Ethan Lin
e9e332b74c Bug 1414264 - Check invalidation region when we use layer system to paint items. r=jrmuizel
MozReview-Commit-ID: Dc5e13NQmP5

--HG--
extra : rebase_source : e4f96edcd5e6dcc75d916aad28c3507ee8bdc7b6
2017-11-07 14:40:08 +08:00
Ryan Hunt
3a2498f61a Flush any buffer operations that may be running after EndEmptyTransaction before EndTransaction (bug 1416308, r=dvander)
MozReview-Commit-ID: CpdtwW2JNip

--HG--
extra : rebase_source : 20e46df173896d5d4fef7f0a9c0989096cd14daa
2017-11-10 13:12:15 -05:00
Milan Sreckovic
639eb384ce Bug 1416306 - Make the function argument a const& instead of passing by value. r=mstange 2017-11-10 10:29:00 -05:00
Nathan Froyd
68ce6c6d2a Bug 1415961 - construct {Blur,Gradient}CacheData more efficiently; r=jrmuizel
We pass in `const {Blur,Gradient}CacheKey&` to these functions.  There's
no need to copy the cache keys here; we can just Move() the existing
objects in instead.  Doing this saves unnecessary allocations and/or
refcounting.
2017-11-10 16:43:54 -05:00
Ryan VanderMeulen
b16410f51c Merge inbound to m-c. a=merge 2017-11-10 16:13:15 -05:00
Ryan VanderMeulen
f09d55fcf6 Backed out changeset f296220f4117 (bug 1415762) for frequently crashing with mozilla::BlockingResourceBase::CheckAcquire(), RtlEnterCriticalSection and _pthread_mutex_lock. 2017-11-10 16:06:34 -05:00
Jeff Muizelaar
0d413c707d Bug 1415326. Tolerate slight changes in scale for fallback items. r=ethlin
This helps us avoid rerasterizing the blob images every frame.  This makes a
huge difference in performance. Our score goes from approx 75 to 380. Current
Firefox gets about 200.
2017-11-10 13:19:11 -05:00
Kartikaya Gupta
c13feff999 Bug 1415150 - Update webrender to commit f58ed651b47f47382b63dd2bce6e4ed10ee18c78. r=jrmuizel
MozReview-Commit-ID: 8wGfwYlhJ1N

--HG--
extra : rebase_source : 4554d38e38c76902ffdb27a4b773d31ccf8868c2
2017-11-10 10:55:05 -05:00
Jonathan Kew
a889197da2 Bug 1412090 - patch 2 - Rework the fontconfig-based platform font list implementation to pass the list of available font patterns from chrome to content, instead of letting the content process get it directly from fontconfig. r=lsalzman 2017-11-02 20:29:33 +00:00
Jonathan Kew
c28cae074c Bug 1412090 - patch 1 - Wrap the font family record used to pass font info from chrome to content on macOS in a union, in preparation for using the same mechanism with a different type of font record on Linux. (No functional change here, just the added union type and some renamings from 'font family list' to 'font list' to be more generic.) r=lsalzman 2017-11-02 17:23:16 +00:00
Chris Peterson
0e8425b401 Bug 1416164 - Replace NS_ABORT with MOZ_ASSERT_UNREACHABLE. r=froydnj
MozReview-Commit-ID: DRdYlOYqZpN

--HG--
extra : rebase_source : b20fb24abf0f2ce648c12a827532c0dbeefb6c63
2017-10-24 23:52:56 -07: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
Kartikaya Gupta
970ae8d67f Bug 1417062 - Update for API change in WR PR 2043. r=nical
MozReview-Commit-ID: 1tkg8G6BT2Q

--HG--
extra : rebase_source : c12aedca9dc1f558a89172478b16a16aa039f059
2017-11-17 08:43:49 -05:00
Kartikaya Gupta
6b90531555 Bug 1417062 - Update webrender to commit d490a74c438d987122c600afca6bb2247ab38637. r=nical
MozReview-Commit-ID: 4i2RKAFTAMd

--HG--
extra : rebase_source : df9734e5475a2d0e133553dbb10b07f417d5b985
2017-11-17 08:42:23 -05:00
Daosheng Mu
03cbcf3594 Bug 1405600 - Part 1: Initialize uniform blocks before detaching shaders; r=jgilbert
ANLGE has resolved this issue at 753521

MozReview-Commit-ID: 4fQ1XuGxWLn

--HG--
extra : rebase_source : f82449ebce036a646a0e9281f9cfec4d1b5a9a47
2017-10-30 17:34:37 +08:00
Timothy Guan-tin Chien
93fb9c8b32 Bug 1327097 - Part III, Trap mouse/touch/pointer events in audio/video element, r=smaug
This patch implements HTMLMediaElement::GetEventTargetParent and set
aVisitor.mCanHandle to false to mouse/touch/pointer events, when
the media control is present. This tells the event dispatcher that
these events are supposed to be handled exclusively by the
videocontrol binding within the media element, and should not
dispatch nor consumed by the content.

MozReview-Commit-ID: BXWZX9SYsuC

--HG--
extra : rebase_source : 5d6633a2e1a456d2d619b6f68498065d94c68c40
2017-11-17 11:07:12 +08:00
Ethan Lin
58b09d8e57 Bug 1416620 - Part2. Add a reftest for button border with inset shadow and empty border. r=kats
MozReview-Commit-ID: Jr3rm6fpgg8

--HG--
extra : rebase_source : 934fe71290ea4f51163b776efb559e0de72a0ae9
2017-11-13 13:55:33 +08: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
sotaro
35956656da Bug 1414727 - Change AsyncImagePipeline::mIsChanged flag handling as to reduce DisplayList update r=nical 2017-11-15 10:14:06 +09:00
sotaro
a15823ac76 Bug 1416614 - Add checks to ImageBridgeParent::NotifyImageComposites r=nical 2017-11-15 09:08:18 +09:00
Kartikaya Gupta
9e0fc459e6 Bug 1416258 - Update webrender to commit 8a39cf24f493e894a66c2465dd310a2b2923e558. r=jrmuizel
MozReview-Commit-ID: IjTJa62Op9b

--HG--
extra : rebase_source : 2de0202e76d7ffd58b01ad9f90b8a9660a2022cf
2017-11-14 09:19:11 -05:00
Kartikaya Gupta
0b55cc54f3 Bug 1416073 - Avoid calling the expensive ComputeScrollMetadata function if we already computed that metadata before. r=jrmuizel
MozReview-Commit-ID: 5SwAEA4Wpqw

--HG--
extra : rebase_source : 1c717c3f0cfb1c5a94970d5d7cc267ee9570c0ad
2017-11-09 23:18:39 -05:00
sotaro
56c2f9bf58 Bug 1412249 - Fix DidComposite timing for EmptyTransaction r=nical 2017-11-15 08:00:57 +09:00
sotaro
03a781381b Bug 1416594 - Add SurfaceFormat::R8G8B8A8 handling to SurfaceFormatToImageFormat() r=nical 2017-11-15 07:15:11 +09:00
Jonathan Kew
7036cc5f85 Backed out changesets 75e7f32c3365, eec946b59360, 72a6f5f3512c, ea8ee40ed426 (bug 1412090) for apparently breaking all system-installed fonts on some Linux systems. r=backout 2017-11-10 16:05:33 +00:00
Ryan Hunt
ac638de2f4 Don't do PaintThebes after PaintOffMainThread. (bug 1399692 part 10, r=dvander)
MozReview-Commit-ID: J0IOzqIGRtz

--HG--
extra : rebase_source : d20a570de201dc46ceb3605db20af40f2f2fed8e
extra : source : eab96d73c39df98c888a491f54fbb963069c5f6b
2017-11-09 15:44:21 -05:00
Ryan Hunt
84c229fe9d Don't reuse a back buffer after a swap if the content or surface changed (bug 1399692 part 9, r=bas)
MozReview-Commit-ID: HGAxkeyESbc

--HG--
extra : rebase_source : 7c09e853a3feeb1d1d9d7cc93d77242265ec590b
extra : source : 7d9324e2ab34946539be9f17d74f639aae5ba7e5
2017-11-05 10:38:47 -05:00
Ryan Hunt
9dc07b61c4 Don't copy over regions that will be painted in this frame (bug 1399692 part 8, r=bas)
We do the same in FinalizeFrame, so we should do it here.

MozReview-Commit-ID: JTKDj8yrtI2

--HG--
extra : rebase_source : 6ba114c6734990dcb62e361889d1b2cf2b5ad7dc
extra : intermediate-source : 76bf99decf0906f0a6a4ad99539fd40f97c4539f
extra : source : fb9b0524428307c4ee097894e37879339df47579
2017-11-04 14:52:31 -04:00
Ryan Hunt
c34dc7e2af Replay buffer commands on paint thread when OMTP is enabled (bug 1399692 part 7, r=bas)
This commit does the work of actually dispatching the recorded buffer operations
to the paint thread, and removing some main thread asserts from TextureClient.

MozReview-Commit-ID: CN3RoQPz9fP

--HG--
extra : rebase_source : 08ae6cf8445ef0a757efc54175768c2fa9bb1685
extra : intermediate-source : 0fc2414f146d8f5d08c97e5b7eedb25c5632ab2d
extra : source : e9349ad2f1f8fec862b1d2271d0d8f25ad0814d4
2017-10-26 00:47:17 -04:00
Ryan Hunt
cc9ba81109 Record buffer operations to a struct for replaying on paint thread (bug 1399692 part 6, r=bas)
This commit adds a CapturedBufferState which is used to record all the operations
that are necessary for preparing the buffers. The commands are then instantly
executed to preserve the same behavior, but in the following commit they will
be dispatched to the paint thread.

Note: RotatedBuffer's aren't thread safe and so a shallow copy needs to be made
for sending to the paint thread. This complicates the code for AdjustTo as it can
fail naturally and the buffer parameter changes are needed later in BeginPaint.
So the code for AdjustTo is split up a bit to accomodate that.

MozReview-Commit-ID: FwSwFay887o

--HG--
extra : rebase_source : 70dd8a055aaa13586810030978409d1a89c39081
extra : intermediate-source : f235b12eda6efe0bdec8e6590d813738f53ffe82
extra : source : cb6507b560aaad188fc83a47b664aaa5692a0acd
2017-10-25 10:20:49 -04:00
Ryan Hunt
1c5e585bd6 Simplify copying the front buffer to the back buffer (bug 1399692 part 5, r=bas)
To sync the back buffer with the front buffer, we set the back buffer rect and
rotation to the front buffer's, and then copy over the pixels that different.

We used to do the updating of the rect and rotation before BeginPaint, but that
isn't necessary and we can move it to be with the copying of pixels.

MozReview-Commit-ID: HzBKvMZkn1

--HG--
extra : rebase_source : 053e55df273d0d89327b80bc599ee05a020f6fef
extra : intermediate-source : 467532fd5b7a2385ba0dbdb9201e28e8f2b4a583
extra : source : 3d0da65640964e5a0565b5e7b7646cf719ce1449
2017-10-23 18:27:53 -04:00
Ryan Hunt
8348d444d0 Don't create back buffer for front buffer until we know what type to create. (bug 1399692 part 4, r=bas)
This commit is an optimization for double buffering that delays the creation of
a back buffer until we know what kind of content type it needs to be.

Before this commit, we would EnsureBackBufferIfFrontBuffer before BeginPaint,
then in BeginPaint we could determine that we actually needed a different kind
of buffer because the content changed type, and recreate it.

This was needed because BeginPaint would copy the old front buffer to the buffer
created by EnsureBackBufferIfFrontBuffer, and then if anything failed or we had
determined we couldn't reuse the buffer, we would create a new one and copy that
"temporary" back buffer over, and use the new one.

This is unnecessary because we only need read access on that "temporary" back
buffer, and so we can just use the current front buffer instead.

This optimization only affects the double buffered case, and the single buffered
or basic cases should remain the same.

Note: Because we now need the front buffer for copying into the new back buffer,
we cannot Clear() it away in some error cases.

Note: The code in FinalizeFrame assumes that the back and front buffer have the
same size. This was implicitly enforced before, and now needs to be explicitly
enforced. This commit tries to preserve the exact same behavior, although the
restriction should be removed as long as the back buffer is large enough for
the visible region.

MozReview-Commit-ID: 2hyrrUhA4zO

--HG--
extra : rebase_source : 5db62a4d24383c7d64e127880a3bee7ff76dada1
extra : intermediate-source : dce585be0737f3c9b6b241afb0851d85fb9453c9
extra : source : 926af2eca400cf8a16777813ceb586b1d3be7d68
2017-10-23 15:33:40 -04:00
Ryan Hunt
56b43edede Remove BufferContentType and add ValidBufferSize (bug 1399692 part 3, r=bas)
BufferContentType and BufferSizeOkFor make more sense as general functions for
any RotatedBuffer, and this helps out in a later patch.

MozReview-Commit-ID: EAVodvl4WTu

--HG--
extra : rebase_source : 122b6466ef0194d6ff682d677db01312c9e27a2a
extra : intermediate-source : b971c1aa5a78c17d49d1d64389516437024be72a
extra : source : b57a3f0d08478f094328b5a50c57eed35798fdf0
2017-10-23 14:56:13 -04:00
Ryan Hunt
37f9020f14 Simplify the code for creating a new back buffer (bug 1399692 part 2, r=bas)
MozReview-Commit-ID: D28JNYWD9Uc

--HG--
extra : rebase_source : 089014bebbf97af2eeb5b940cf468411b753c428
extra : intermediate-source : 8ba8bda8521a6460b1213d2d0f14ebefc0a3e14a
extra : source : 9fcb661df79e51c80f5ffb24717dba655dc97d73
2017-10-23 12:40:01 -04:00
Ryan Hunt
c6550ebd1e Remove unneeded lambda capture in paint thread (bug 1399692 part 1, r=bas)
MozReview-Commit-ID: 71X22PHRTRz

--HG--
extra : rebase_source : 1d1016e48054c39a615c31880e4aa8a38f426bf0
extra : intermediate-source : 2c41a712dff22de4fb2bbfd7c5a418fbc3a26f11
extra : source : 744c8fabaa1c3e6b7322cd2b4c6672b8509c643c
2017-10-31 01:55:24 -04:00
JerryShih
7fa50ff43a Bug 1415816 - integrate gfxCriticalNote/gfxCriticalError for WebRender in gpu process. r=kats
MozReview-Commit-ID: 3Mey7XRYRn6
2017-11-10 07:30:53 -05:00
sotaro
a8b71fcd72 Bug 1415763 - Fix DXGIYCbCrTextureData as to deliver YUVColorSpace r=mattwoodrow 2017-11-10 18:15:54 +09:00
Milan Sreckovic
7d3551d146 Bug 1281965 - Sometimes we don't want to add when searching for a family. r=jfkthame
--HG--
extra : rebase_source : c1b0ecc2cc221395947326c440e01cbb6b0044fc
2017-11-09 18:38:30 -05:00
Sebastian Hengst
8c31f6f143 Backed out changeset d0ddd9a98e74 (bug 1415961) for bustage in thebes. r=backout on a CLOSED TREE 2017-11-10 00:11:59 +02:00
Nathan Froyd
d553d84aeb Bug 1415961 - construct {Blur,Gradient}CacheData more efficiently; r=jrmuizel
We pass in `const {Blur,Gradient}CacheKey&` to these functions.  There's
no need to copy the cache keys here; we can just Move() the existing
objects in instead.  Doing this saves unnecessary allocations and/or
refcounting.
2017-11-09 17:03:11 -05:00
Andreea Pavel
e1c8aba28f Merge mozilla-central to mozilla-inbound r=merge a=merge on a CLOSED TREE 2017-11-09 22:17:00 +02:00
Andreea Pavel
5e4025c975 Backed out 9 changesets (bug 1399692) for failing reftest/tests/layout/reftests/svg/dynamic-text-06.svg Windows 10 x64 Stylo Disabled debug R-e10s2 r=backout on a CLOSED TREE
Backed out changeset 7d9324e2ab34 (bug 1399692)
Backed out changeset 76bf99decf09 (bug 1399692)
Backed out changeset 0fc2414f146d (bug 1399692)
Backed out changeset f235b12eda6e (bug 1399692)
Backed out changeset 467532fd5b7a (bug 1399692)
Backed out changeset dce585be0737 (bug 1399692)
Backed out changeset b971c1aa5a78 (bug 1399692)
Backed out changeset 8ba8bda8521a (bug 1399692)
Backed out changeset 2c41a712dff2 (bug 1399692)
2017-11-09 21:55:32 +02:00
Kartikaya Gupta
54431ae212 Bug 1415225 - Add a couple of mochitests for event-regions overrides. r=botond
These two tests exercise the codepaths where an event regions override
is set on (a) the root layer of a layer tree and (b) on an in-process
subdocument. I verified that case (b) was failing with webrender enabled
without the patchset and passes now.

MozReview-Commit-ID: Kw6TQjNupSa

--HG--
extra : rebase_source : ce54c46c7d0470b693e82ae3e477b3702155e59d
2017-11-09 09:03:53 -05:00
Kartikaya Gupta
3c76c8128a Bug 1415225 - Move the EventRegionsOverride field to be on RefLayers only. r=botond
We now set EventRegionsOverride flags on ref layers only, so
there's no need to have the APIs to set it on container layers in
general.

MozReview-Commit-ID: JKU4UXvdR2e

--HG--
extra : rebase_source : 77f49787e8953520dc56ea4a8f9286b35d6942b8
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
d5cf7941e2 Bug 1415225 - Remove dead code. r=jrmuizel
This code has been unused since the removal of layers-full WR codepaths.

MozReview-Commit-ID: JQn55Kbz5rr

--HG--
extra : rebase_source : af6995265c02a1ddfccbc37adb633bc2b240ec8b
2017-11-09 09:03:51 -05: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
David Anderson
d3b572527a Don't fallback to DrawTargetCairo in TextureClient. (bug 1413862, r=mattwoodrow) 2017-11-08 16:57:25 -08:00
Daosheng Mu
6e5d5d2b20 Bug 1411838 - Part 2: Fix non thread-safe objects in VR; r=kip
MozReview-Commit-ID: EzbNWU17qAP

--HG--
extra : rebase_source : ab04d09ad82b6e4acd6f20d60108672d20e0b843
2017-11-09 10:54:36 +08:00
Daosheng Mu
11ecbe54cb Bug 1411838 - Part 1: Enable WebVR reftest for Windows debug; r=kip
MozReview-Commit-ID: A8drAvmATUZ

--HG--
extra : rebase_source : a1d91e76d42afa3c0f3479918d376159409585dc
2017-11-09 10:52:22 +08:00
Noemi Erli
8d8df3ddfe Merge mozilla-central to mozilla-autoland. r=merge a=merge CLOSED TREE 2017-11-10 12:43:53 +02:00
Daosheng Mu
08ffc52b07 Bug 1415762 - Cancel VRListener task when CompositorVsyncScheduler is going to destroy; r=dvander
MozReview-Commit-ID: F25LE5Ru9gz

--HG--
extra : rebase_source : c870e2a987fd4a113d67e6672eb1e53a030fad65
2017-11-09 11:41:15 +08:00
Markus Stange
a8ad9935d6 Bug 1416011 - Make the RoundedRect constructor take const references. r=kats
MozReview-Commit-ID: HC9JKt2EBdq

--HG--
extra : rebase_source : f18ae340a644cab6cddce3273bc68ccf4a44935f
2017-11-09 17:07:32 -05:00
Jonathan Kew
f35b992490 Bug 1412090 - patch 4 - Also adopt the ContentParent::NotifyUpdatedFonts method on macOS, so that only the parent process needs to register with CFNotificationCenter for font-changed notifications. r=lsalzman 2017-11-09 16:54:37 +00:00
Jonathan Kew
1177becaba Bug 1412090 - patch 3 - Check the sandbox policy to verify font files will be readable by the content process before including them in the system font list. r=gps 2017-11-09 16:54:30 +00:00
Jonathan Kew
0ba9f9c57b Bug 1412090 - patch 2 - Rework the fontconfig-based platform font list implementation to pass the list of available font patterns from chrome to content, instead of letting the content process get it directly from fontconfig. r=lsalzman 2017-11-02 20:29:33 +00:00
Jonathan Kew
90bf3da506 Bug 1412090 - patch 1 - Wrap the font family record used to pass font info from chrome to content on macOS in a union, in preparation for using the same mechanism with a different type of font record on Linux. (No functional change here, just the added union type and some renamings from 'font family list' to 'font list' to be more generic.) r=lsalzman 2017-11-02 17:23:16 +00:00
Jonathan Kew
a7a8736435 Bug 1415880 - Remove the obsolete mIsValid flag from gfxFontEntry, as nothing depends on it any more. r=jrmuizel 2017-11-09 16:54:02 +00:00
Ryan Hunt
6e900ce0c3 Don't reuse a back buffer after a swap if the content or surface changed (bug 1399692 part 9, r=bas)
MozReview-Commit-ID: HGAxkeyESbc

--HG--
extra : rebase_source : df5c404aaf3a613affadf4bfd77ca1fc3765f332
2017-11-05 10:38:47 -05:00