Commit Graph

61336 Commits

Author SHA1 Message Date
Jan Henning
8a6b5c9c8a Bug 1328868 - Part 2 - Apply the system font scale as an additional text zoom factor to all pages that are not font inflated. r=tnikkel
We want to use a similar model as Chrome on Android does for scaling our display of web content, that is use font inflation for desktop pages and plain text zooming for everything else.

Since we don't want to simply clobber any text zoom that might have been set by the user/front-end code, we allow setting and storing the system font scale separately on the PresContext. We then calculate the effective text zoom value as the product of the system font scale and the current text zoom value.

Any function that is using the PresContext's TextZoom value for layouting/rendering is switched over to this new EffectiveTextZoom value, whereas functions that are interested in the text zoom as actually set by the user/front-end (e.g. the nsDocumentViewer, or the code responsible for copying text and full zoom settings into the new PresContext on page navigation) continue using the plain TextZoom value.

As long as font inflation is enabled in principle (e.g. font.size.inflation.minTwips != 0), every page starts out as eligible for font inflation until the relevant meta viewport tags marking the page as "mobile friendly" have been detected. Since the PresShell caches the font inflation state and only recalculates it when necessary, we make use of that and set the PresContext's system font scale as necessary whenever the font inflation state has been refreshed.

MozReview-Commit-ID: 2InyE04wKAW

--HG--
extra : rebase_source : 3f6d7128f37c1dc18f67a6655f86d9a3003fe90b
extra : source : 6100458b97289f9aea5ac8fda57ded045e6860b7
2017-02-25 13:22:52 +01:00
Phil Ringnalda
3486d4cb15 Merge m-i to m-c, a=merge 2017-03-25 18:39:56 -07:00
Olli Pettay
a3c7a46e9c Bug 1349946, ensure expected focus handling when redirecting focus, r=enndeakin
--HG--
extra : rebase_source : a68db23cab07124ebdff46d19f7bbb9233167e85
2017-03-25 03:01:19 +02:00
Wes Kocher
9b400ba56f Merge m-c to inbound, a=merge
MozReview-Commit-ID: GakWNxnTzy2
2017-03-24 17:19:20 -07:00
Wes Kocher
6d0b00069c Merge inbound to central, a=merge
MozReview-Commit-ID: JGfQoBJy2jt
2017-03-24 17:17:27 -07:00
Ben Kelly
a68b3b11fd Bug 1350433 Expose WorkerPrivate::ServiceWorkerScope() instead of using WorkerName() all over the place. r=asuth 2017-03-24 19:56:48 -04:00
Sebastian Hengst
e750fa88bd Backed out changeset cc384918477b (bug 1339537) 2017-03-24 21:24:01 +01:00
Sebastian Hengst
5ad6b0372f Backed out changeset 828eba714030 (bug 1339537) 2017-03-24 21:23:56 +01:00
Michael Layzell
e324a5e209 Bug 1339537 - Part 3: Pass FilterPrimitiveDescription by const reference in AddLightingAttributes, r=mstange
MozReview-Commit-ID: J3m2uzv7jW0
2017-03-24 15:51:26 -04:00
Michael Layzell
29d2a6cf0d Bug 1339537 - Part 2: Pass IntIntervals by const reference in TestIntervalSet, r=jya
MozReview-Commit-ID: BGg1yS2Ovhz
2017-03-24 15:51:26 -04:00
Ben Kelly
4ffa062ade Bug 1350398 Remove Workers.h include from BindingUtils.h now that ThrowDOMExceptionForNSResult no longer exists. rs=bz 2017-03-24 15:27:11 -04:00
Emilio Cobos Álvarez
fe28d71e3d Bug 1341102: More reftest updates. r=emilio
MozReview-Commit-ID: CAsplZW4mpj
2017-03-25 18:35:24 +01:00
Emilio Cobos Álvarez
045eb695b0 Bug 1350050: Remove unneeded nsTextFrame casts in ContentEventHandler. r=smaug
MozReview-Commit-ID: FcSYAuQSHUt

--HG--
extra : rebase_source : 41b23e164e721334923a0f3f16e65be80d4f667f
2017-03-23 20:41:58 +01:00
Bobby Holley
887595286b Bug 1350115 - Squelch post-traversal generated by additional animation traversals when we're styling a fresh subtree. r=heycam,r=birtles
This patch exists to avoid a crash in layout/style/test/test_animations.html. We end up
generating some ::before content, which causes us to style the new subtree at [1]. In
StyleNewSubtree, we fail the !postTraversalRequired assertion because
PrepareAndTraverseSubtree decided to traverse the tree twice (once to style it, and again
to restyle it for animations), and return that a post-traversal is needed.

The reason this issue happens with my NAC patches and not without is that we were previously
filtering out generated ::before content from the servo traversal, so the servo traversal
wouldn't have reached it and (presumably) the animation restyle wouldn't have happened and
we wouldn't have returned true for needing a post-traversal.

[1] http://searchfox.org/mozilla-central/rev/c48398abd9f0f074c69f2223260939e30e8f99a8/layout/base/nsCSSFrameConstructor.cpp#1918

MozReview-Commit-ID: 8tgzLjV8B3A
2017-03-24 09:40:30 -07:00
Nicolas Silva
0f4ab75a96 Bug 1309200 - Backed out changeset 0447969a62c2 due to test failures. r=me 2017-03-24 15:22:36 +01:00
Sebastian Hengst
0b29125389 Backed out changeset 7474a804fd1f (bug 1346247) for asserting at MozPromise.h:911. r=backout 2017-03-24 15:05:03 +01:00
Sebastian Hengst
0f1641164f Backed out changeset 804f99e05804 (bug 1346247) 2017-03-24 15:04:27 +01:00
Sebastian Hengst
5b2cf78b72 Backed out changeset 77fc6f341fef (bug 1346247) 2017-03-24 15:04:23 +01:00
Carsten "Tomcat" Book
5f408d092d Merge mozilla-central to mozilla-inbound 2017-03-24 14:29:00 +01:00
Carsten "Tomcat" Book
7419b36815 merge mozilla-inbound to mozilla-central a=merge 2017-03-24 14:24:21 +01:00
Sebastian Hengst
acd397dee7 Backed out changeset ddbfa3adcfad (bug 1338277) for failing own crashtest. r=backout 2017-03-24 13:52:59 +01:00
Andrea Marchesini
481fd60471 Bug 1346247 - Bug 1346247 - Avoid race conditions when SW are updated - part 3 - MozPromise, r=bkelly 2017-03-24 13:22:21 +01:00
Andrea Marchesini
b5268bafe7 Bug 1346247 - Bug 1346247 - Avoid race conditions when SW are updated - part 2 - tests, r=bkelly 2017-03-24 13:21:42 +01:00
Andrea Marchesini
561e3f5ffd Bug 1346247 - Bug 1346247 - Avoid race conditions when SW are updated - part 1 - PServiceWorkerUpdater actor, r=bkelly
In this patch I introduce a new actor: PServiceWorkerUpdater managed by
PServiceWorkerManager and running on PBackground. Each time a SoftUpdate() or
Update() operation starts, a PServiceWorkerUpdater is used for having a unique
lock for the update of a particular scope+originAttributes.
The implementation happens on the PBackground thread of the parent process,
where all these PServiceWorkerUpdater actors are taken in an array and, only
the first one for each scope+originAttributes is activated.
2017-03-24 13:21:18 +01:00
Iris Hsiao
26a234de5d Backed out 6 changesets (bug 1347758) for eslint failure
Backed out changeset 9becd55242c1 (bug 1347758)
Backed out changeset 2abce19f5001 (bug 1347758)
Backed out changeset 80232d4c85d5 (bug 1347758)
Backed out changeset 1fd084ec34d4 (bug 1347758)
Backed out changeset cafb3c12027b (bug 1347758)
Backed out changeset 85846edfe957 (bug 1347758)
2017-03-24 16:58:08 +08:00
Chris Pearce
0901ad8256 Bug 1315850 - Ask the GMPService for the GMP thread in GMPParent::ChildTerminated. r=gerald
When we shutdown the browser while the GMPService is active we can end up
leaking a GMPParent, GeckoMediaPluginServiceParent, and a Runnable. I tracked
this down to the runnable dispatched to the GMP thread in
GMPParent::ChildTerminated(). The dispatch of this runnable is failing as we
are dispatching the runnable to a reference of the GMP thread which we have
previously acquired, but that thread is now shutdown. So the dispatch fails,
and if you look in nsThread::DispatchInternal() you'll see that we deliberately
leak the runnable if dispatch fails! The runnable leaking means that the
references it holds to the GMPParent and the GMP service parent leak.

The solution in this patch is to not cache a reference to the GMP thread on the
GMPParent; instead we re-request the GMP thread from the GMPService when we
want it. This means that in the case where the browser is shutting down,
GMPParent::GMPThread() will return null, and we'll not leak the runnable. We'll
then follow the (hacky) shutdown path added in bug 1163239.

We also need to change GMPParent::GMPThread() and GMPContentParent::GMPThread()
to return a reference to the GMP thread with a refcount held on it, in order
to ensure we don't race with the GMP service shutting down the GMP thread
while we're trying to dispatch to in on shutdown.

MozReview-Commit-ID: CXv9VZqTRzY

--HG--
extra : rebase_source : e507e48ee633cad8911287fb7296bbb1679a7bcb
2017-03-24 13:38:00 +13:00
Alastor Wu
e81c17d1b2 Bug 1347758 - part4 : add audio channel log. r=Ehsan
MozReview-Commit-ID: LNXzRZx2rC2

--HG--
extra : rebase_source : eef0ad3d65161c422d3cab57e6e081796452bdd1
2017-03-24 12:04:15 +08:00
Alastor Wu
1119f7369f Bug 1347758 - part3 : should notify media block for audible agent in the first time. r=Ehsan
When the agent is audible, we should check whether need to notify "blockStart"
immediately.

MozReview-Commit-ID: KmYLo9cEt4X

--HG--
extra : rebase_source : 5f29de593b85113001552ff0497621e603b40bc6
2017-03-24 12:04:00 +08:00
Alastor Wu
8591f98cad Bug 1347758 - part2 : remove add/removeMediaContent() and related codes. r=Ehsan
Since the window would know when need to resume the media, we don't need the
add/removeMediaContent() anymore.

MozReview-Commit-ID: F9MSiqqnOiV

--HG--
extra : rebase_source : 28a8312373054b8e29b93267677de99dd862a074
2017-03-24 12:01:46 +08:00
Alastor Wu
8b4c678479 Bug 1347758 - part1 : window should know whehter there is any alive media component and decide to resume the tab or not. r=Ehsan
We should let window decide whether resume the media component, not document.
Because we might have media component which is not in DOM tree, but we still
want to play it.

Window should be resumed when all following conditions are true,
(1) the tab is in the foreground
(2) there is any alive media component (MediaElement/WebAudio/PlugIn...)
(3) the window is blocked (nsISuspendedTypes::SUSPENDED_BLOCK)

MozReview-Commit-ID: JXw5MA4FCxF

--HG--
extra : rebase_source : 416113dd2282a979ea26c4694878c2f2db578274
2017-03-24 12:01:43 +08:00
Ting-Yu Lin
4e375689c6 Bug 1322570 Part 4 - Use GetParentAllowServo() in KeyframeEffectReadOnly::UpdateProperties. r=hiro
Per bug 1322570 Comment 7, we could drop the GetParentAllowServo() when we
invoke UpdateProperties() from a SquentialTask, so allow it for now.

MozReview-Commit-ID: 52NauGaz4Zv

--HG--
extra : rebase_source : 617c3310a042ca49023ebad1801a2c283e4e212c
2017-03-20 14:13:01 +08:00
JW Wang
b783d4fca2 Bug 1350203. P6 - rename SWARN to SLOGW. r=kaku
MozReview-Commit-ID: HEPJ6Ktj8UH

--HG--
extra : rebase_source : 0eda6d4aaf1b7adcda937a1d2e99a332dc3e76e3
2017-03-24 12:42:49 +08:00
JW Wang
5274c2cb96 Bug 1350203. P5 - replace SAMPLE_LOG with LOGV. r=kaku
We often need to turn on both MediaSample and MediaDecoder logs when debugging sample activities.
So it is convenient to merge them into a single log module.

Use `MOZ_LOG=MediaDecoder:4` to show decoder logs.
use `MOZ_LOG=MediaDecoder:5` to show both decoder and sample logs.

MozReview-Commit-ID: JQtyoyrNRmV

--HG--
extra : rebase_source : 85739da85aa4059b058a9baccd5509c8149712d8
2017-03-24 11:58:37 +08:00
JW Wang
a69e7de100 Bug 1350203. P4 - change the level of MediaSink logs. r=kaku
1. Use LOG() for OnMediaSink{Audio,video}Complete() which is not verbose.
2. Use LOGW() for OnMediaSink{Audio,Video}Error() which indicates an error.

MozReview-Commit-ID: 4Z5U32YlMPB

--HG--
extra : rebase_source : 2b2da51c17b6c7d9b4ec8b0f274c9ed018631374
2017-03-24 11:43:57 +08:00
JW Wang
83dc3dc981 Bug 1350203. P3 - rename DECODER_WARN to LOGW. r=kaku
MozReview-Commit-ID: 3dstP1KkBJh

--HG--
extra : rebase_source : ad40556a87cd205bd94331c396f7a2255c4a6d44
2017-03-24 11:38:22 +08:00
JW Wang
2641e73ea3 Bug 1350203. P2 - rename VERBOSE_LOG to LOGV. r=kaku
MozReview-Commit-ID: IM8t69P5dU4

--HG--
extra : rebase_source : dc6325c87c368079c766f884551db1baba67c7f9
2017-03-24 11:35:45 +08:00
JW Wang
3fd71fee63 Bug 1350203. P1 - rename DECODER_LOG to LOG. r=kaku
MozReview-Commit-ID: nL4fiALn5N

--HG--
extra : rebase_source : c61b084c062aa0da6551c1f06cb10353518dd995
2017-03-24 11:33:06 +08:00
JW Wang
79d42d9703 Bug 1350202 - use shorter names for logging macros in MediaDecoder.cpp. r=kaku
MozReview-Commit-ID: E2OnbXb82Zb

--HG--
extra : rebase_source : d1de2002a7bb446b10aaeb4e03a56ce3a63f6ae4
2017-03-24 11:17:17 +08:00
Mats Palmgren
2dd8c9d161 Bug 1333482 part 6 - [css-ui] Manually tweak some tests for 'appearance' changes. r=dholbert
MozReview-Commit-ID: 9cBAQIeS2TG
2017-03-23 22:11:25 -07:00
Mats Palmgren
00b74113a3 Bug 1333482 part 4 - [css-ui] Amend all uses of '-moz-appearance:none' in tests to also specify 'appearance:none' (automated change). r=dholbert
MozReview-Commit-ID: BNOR5VRpV2E
2017-03-23 22:11:22 -07:00
Kartikaya Gupta
b6566b9f0c Bug 1349949 - Turn some advanced layers prefs into override prefs. r=mchang
This allows us to remove the #ifdef MOZ_ENABLE_WEBRENDER for the advanced layers
prefs from all.js. As additional advanced layers are turned on for webrender (or
non-webrender) they can be converted into override prefs without affecting the
call sites.

MozReview-Commit-ID: F9tMc23ow8A

--HG--
extra : rebase_source : 2244cb000711496ce5b7f1b50ef0314e1c312d94
2017-03-23 16:29:54 -04:00
Chris Pearce
6d19fe826f Bug 1315850 - Port the work around from Bug 1343140 to the new CDM video decoder architecture. r=gerald
MozReview-Commit-ID: EV0bieXIxYM

--HG--
extra : rebase_source : 404709f1aee80465a953fce1a1e715d49ebfbe35
2017-03-14 17:17:05 +13:00
Chris Pearce
e156a08c17 Bug 1315850 - Rename DetailedPromise Status enum. r=gerald
X11.h #defines 'Status' and 'Failed' and 'Succeeded' which conflicts with
the enum in DetailedPromise. So rename the 'Status' enum in DetailedPromise
so that the build works on Linux.

Some of my changes here caused DetailedPromise to be included in more
places that it was before, which caused build failures on Linux.

MozReview-Commit-ID: KV5xKixXR3J

--HG--
extra : rebase_source : ef6cab901d74b78f613660f263f5e453d6044536
2017-03-13 10:42:36 +13:00
Chris Pearce
caac622c6d Bug 1315850 - Implement CDM persistent sessions. r=gerald
This is required for the browser clearing persistence tests to pass.

MozReview-Commit-ID: Ai9qc6Ds1IG

--HG--
extra : rebase_source : 80c2133e26742410fda983e3c18c35736fc013d0
2017-03-09 19:09:43 +13:00
Chris Pearce
cfe7c116ce Bug 1315850 - Hook up CDM storage. r=gerald
MozReview-Commit-ID: 9gHcMZvmMfg

--HG--
extra : rebase_source : 186f35455264aaa144fd7b1887b8ca2476ac03b2
2017-03-22 16:30:54 +13:00
Chris Pearce
bf0e67458a Bug 1315850 - Shutdown ChromiumCDMParent. r=gerald
MozReview-Commit-ID: E82ETFS90eH

--HG--
extra : rebase_source : 6f0d72f76e313b55f7c905d5878c63b8d7292b1b
2017-03-09 17:34:18 +13:00
Chris Pearce
4c421503a8 Bug 1315850 - Shutdown CDMVideoDecoder. r=jya
This severs the ChromiumCDMVideoDecoder's connection with the CDM. The CDM process
will shutdown when the MediaKeys also severs its connection.

MozReview-Commit-ID: Aqc4y5Nxjvc

--HG--
extra : rebase_source : 5a2f77ffe84f9b99b4668520c838b29a428578d3
2017-03-08 10:20:33 +13:00
Chris Pearce
dbc1c7bcdf Bug 1315850 - Implement CDM video decoder drain. r=jya
MozReview-Commit-ID: 5RbrWyLglRf

--HG--
extra : rebase_source : 3f9636503523f0c6effab15fa89cce25a961a0b4
2017-03-07 16:37:21 +13:00
Daosheng Mu
62781e3b7d Bug 1299937 - Part 6: Handle Stop vibrating when the window defoucses; r=qdot
MozReview-Commit-ID: Kvd40jnSPvK

--HG--
extra : rebase_source : f9ce4c68fd07376b8e18cbab08718c49d6fed455
2017-03-07 10:17:57 +08:00
Peter Van der Beken
48e0b293f8 Bug 1338277 - Deal better with failed matching for variables, r=erahm.
--HG--
extra : rebase_source : f91e3884a55d4f667187e8538106bccbc117d3e5
extra : intermediate-source : 421407ec02c07437ced56c950b03c74e6faea56b
extra : source : 5669c2511dec853fecd42dbdc8b1fdfea64c362d
2017-02-20 15:04:51 +01:00