Commit Graph

1272 Commits

Author SHA1 Message Date
Ting-Yu Lin
900bd55b15 Bug 1338446 Part 3 - Label SheetLoadData in Loader::PostLoadEvent. r=heycam
When constructing a Loader without passing a document, we added a DocGroup
parameter so that we could still use it to dispatch events to the DocGroup.

Delete NS_ENSURE_TRUE because new() is infallable.

Use another runnable pointer for calling dispatching because forget() will
nuke the pointer and we need to use evt afterwards.

MozReview-Commit-ID: Ce2K6j4pUhA
2017-03-13 17:00:57 +08:00
Kris Maglione
227525437a Bug 1348523: Store a weak reference to the blocked parser, and use when unblocking. r=hsivonen
Users in nightlies are hitting the assertion in UnblockParser that ensures the
parser is blocked. The only way that should be able to happen is if the
initial parser is destroyed and a new one is created before we try to unblock.
In theory, that shouldn't happen for the initial parser when it's blocked
this early, so my best guess is that an add-on is ending the document load and
then re-opening the document.

MozReview-Commit-ID: iQkE2aWDTZ
2017-03-18 14:20:41 -07:00
Sebastian Hengst
bcb685d9e1 merge mozilla-central to autoland. r=merge a=merge 2017-03-18 16:35:12 +01:00
Kris Maglione
96e9d02181 Bug 1333990: Follow-up: Use Promise& rather than OwningNonNull<Promise> for binding arguments. r=bz
MozReview-Commit-ID: 23aYwjCPJ6l
2017-03-17 13:55:27 -07:00
Kris Maglione
9c4ce2fcac Bug 1333990: Follow-up: Add cycle collection and comments where unnecessary. r=bz
MozReview-Commit-ID: 70omvafFFFH
2017-03-17 13:54:32 -07:00
Cameron McCormack
0344da46e0 Bug 1330843 - Allow JS to create NAC pseudo-elements. r=bholley
MozReview-Commit-ID: 2aBPoCOsT6R
2017-03-17 15:30:34 +08:00
Kris Maglione
e8289edf84 Bug 1333990: Part 2d - Add a utility to block HTML parsing until sandbox scripts are ready. r=hsivonen,billm
In order to asynchronously load content scripts that need to run very early in
the page load cycle, before any ordinary page scripts, we need to be able to
block parsing from the document-element-inserted listener. Since the script
loader operates by returning promises, blocking on promise resolution is the
simplest way to achieve this.

MozReview-Commit-ID: CTWlyrP6dqG
2017-03-16 16:47:35 -07:00
Bevis Tseng
cbf352d0db Bug 1332491 - Delete SelectorCacheKey synchronously. r=bz
1. The current asynchronous behavior is pointless, because we still remove the
   hashtable entry synchronously, which deletes the value, and it's the value
   we're using.
2. Trying to asynchronously delete the value is difficult, and not currently
   needed because we can't get a memory-pressure notification while we're using
   the value, and hence can't expire it from the expiration tracker.
   Note: we can't get this memory-pressure notification because the stage 2 of
   mozalloc_handle_oom() to reclaim memory when OOM is not implemented yet.
2017-03-13 14:37:19 +08:00
Carsten "Tomcat" Book
80b8226308 merge mozilla-inbound to mozilla-central a=merge 2017-03-15 13:12:42 +01:00
Samael Wang
420d13b9bd Bug 1346703 - Replace PR_LogPrint with MOZ_LOG, remove unnecessary checks and add a nullptr check. r=ehsan 2017-03-14 16:58:45 +08:00
Kirk Steuber
82f36355d4 Bug 1345611 - Change behavior of subdocument Flash blocking to be Third-Party Flash blocking r=bsmedberg,qdot
The previous implementation regarding to the Flash Blocking Subdocument list blocked all subdocuments that matched the list. This patch changes that so that subdocuments are only blocked if they are on the Subdocument Block List and also are loaded in a Third-Party context.

The changes to cert8.db and key3.db add the https certificate for subdocument.example.com so that testing can verify that a scheme mismatch between the document and its parent results in a third-party classification.

MozReview-Commit-ID: IXnA4iPzB4y
2017-03-10 10:50:21 -08:00
Manish Goregaokar
be24bd2d60 Bug 1329093 - Part 4: stylo: Delay SVG mapped attr resolution till later; r=bz
MozReview-Commit-ID: 2GvHPg1egjS
2017-03-09 17:46:26 -08:00
Wei-Cheng Pan
7a678cdad2 Bug 1310127 - Part 17: Use MOZ_MUST_USE in netwerk/protocol/http r=smaug
MozReview-Commit-ID: 5gvVZtsa3yS
2016-12-20 11:49:32 +08:00
Alastor Wu
3e5501715a Bug 1338137 - part1 : ref media content when the media element bind to tree. r=baku
In bug1319771, we found that the tab would become visible unexpectly in short
period in some situations. We don't want to resume the tab in this kind of
situation, so we check whether there is any alive media component in the tab
using IsServiceStarted(). However, since we have lots different ways to create
the service, this function is not accurate at all.

Therefore, we can add media element directly to the document when it binds to
tree so that we can really know whether there is any alive media component.

MozReview-Commit-ID: FvZFg91IqgE
2017-03-04 01:14:24 +08:00
Ben Kelly
3e3147f98d Bug 1266747 P1 Track the last focus time on the nsIDocument. r=smaug 2017-02-28 22:12:27 -05:00
Sebastian Hengst
60f5eb6bba Backed out changeset d19ad1c1c214 (bug 1266747) for failing dom/workers/test/serviceworkers/test_claim.html. r=backout 2017-02-28 18:56:14 +01:00
Ben Kelly
eda30dce7a Bug 1266747 P1 Track the last focus time on the nsIDocument. r=smaug 2017-02-28 10:48:51 -05:00
Carsten "Tomcat" Book
b156024e5f merge mozilla-inbound to mozilla-central a=merge 2017-02-24 11:46:38 +01:00
Brad Werth
79bc1141f0 Bug 1290218 Part 8: Implement ServoStyleSheet Clone. r=heycam
MozReview-Commit-ID: Y2KcoMjhbn
2017-02-15 13:33:17 -08:00
Ehsan Akhgari
7965288852 Bug 1341898 - Make nsDocument::IsWebComponentsEnabled use a cached bool pref; r=baku 2017-02-23 13:25:21 -05:00
Andrea Marchesini
5e3def60d4 Bug 1341218 - nsNullPrincipal should serialize its URL, r=qdot 2017-02-23 14:30:23 +01:00
Carsten "Tomcat" Book
a9d738f08d Merge mozilla-central to mozilla-inbound 2017-02-22 14:40:19 +01:00
Jessica Jong
be4c818826 Bug 1340086 - Remove uses of AnimationsPaused() since it is always false after bug 1316330. r=mrbkap 2017-02-22 01:00:00 -05:00
Sebastian Hengst
4b7b49e7d2 Backed out changeset a6267555a244 (bug 1341218) for various test failures, e.g. xpcshell test dom/push/test/xpcshell/test_service_parent.js. r=backout 2017-02-22 11:21:37 +01:00
Andrea Marchesini
4a3922fdec Bug 1341218 - nsNullPrincipal should consider its URI in ::Write/::Read, r=qdot 2017-02-22 10:01:43 +01:00
Cameron McCormack
b16e5f7bca Bug 1337258 - Support ServoStyleSheets in nsStyleSheetService. r=xidorn
MozReview-Commit-ID: 4vaHzDBZHFg
2017-02-21 10:42:27 +08:00
Xidorn Quan
32f8d92717 Bug 1340926 part 2 - Avoid record deprecated operation inside about: pages. r=Ehsan
MozReview-Commit-ID: GksnEDiHboq
2017-02-20 12:35:56 +11:00
Xidorn Quan
02da52f4a5 Bug 1340926 part 1 - Make nsDocument::IsAboutPage usable in const function. r=Ehsan
MozReview-Commit-ID: 6MYH6VAQ911
2017-02-20 12:35:15 +11:00
Tobias Schneider
18718b4035 Bug 1337936 - (intersection-observer) Revise lifetime management. r=smaug
MozReview-Commit-ID: 4pzm00igBLR
2017-02-22 10:45:13 -08:00
Sebastian Hengst
52b71b9942 Backed out changeset b0838d45e9b6 (bug 1335475) for failing e.g. dom/plugins/test/crashtests/539897-1.html. r=backout 2017-03-10 23:28:13 +01:00
Benjamin Smedberg
1030beab71 Bug 1335475 - Deny plugins from non-HTTP/HTTPS origins. r=bytesized,qdot
MozReview-Commit-ID: 3kPeycfMWVw
2017-03-07 09:34:03 -05:00
Boris Zbarsky
2be49a7995 Bug 1339891 part 2. Make FlushPendingNotifications on a presshell quickly no-op if there is nothing to flush. r=heycam 2017-02-17 13:38:44 -05:00
Vedant Sareen
a85a2ad339 Bug 1330907 - Rename Telemetry::ID to Telemetry::HistogramID. r=dexter
Changed |print("enum ID : uint32_t {", file=output)| to |print("enum HistogramID : uint32_t {", file=output)| at line 53 of the file |toolkit/components/telemetry/gen-histogram-enum.py|, and then replaced all the textual occurrences of |Telemetry::ID| to |Telemetry::HistogramID| and |ID| to |HistogramID| in 43 other files.
2017-02-16 00:45:15 +05:30
Boris Zbarsky
36e0f8b6f3 Bug 1335450. Fix our condition for rescheduling frame request callbacks. r=mrbkap 2017-02-15 18:31:36 -05:00
Olli Pettay
142593cd11 Bug 1338886 - nsDocument::UpdateIntersectionObservations() should call perf->Now() only if needed, r=tschneider 2017-02-15 17:04:16 +02:00
Carsten "Tomcat" Book
8c5a1d7423 Merge mozilla-central to mozilla-inbound 2017-02-15 12:43:50 +01:00
Xidorn Quan
4cdc3377d9 Bug 1339341- Downgrade several stylo errors to warnings. r=heycam
MozReview-Commit-ID: 2Sa8dS8uSo5
2017-02-14 18:26:10 +11:00
John Dai
5730d36b65 Bug 1338889 - Part 2: Support DOMString as Argument 3 of Document.createElementNS. r=bz 2017-02-15 00:07:00 +08:00
Kirk Steuber
bdcea14c4d Bug 1338287 - Make nsIDocument::DocumentFlashClassification accessible from privileged JS r=bz
MozReview-Commit-ID: 1II2puZMub5
2017-02-13 13:39:40 -08:00
Bill McCloskey
fa3300d9dc Bug 1337537 - Workarounds to avoid TabGroup assertions in edge cases (r=smaug)
MozReview-Commit-ID: LVTgyivcA7V
2017-02-13 17:03:03 -08:00
Bill McCloskey
3fdff512cf Bug 1337537 - Assert that runnables labeled with a given TabGroup never touch other TabGroups (r=ehsan)
MozReview-Commit-ID: sOdn9e5f57
2017-02-13 17:02:57 -08:00
Bill McCloskey
e9634c7709 Bug 1334346 - DocGroup should be correct for static clone documents (print, print preview) (r=smaug)
MozReview-Commit-ID: f0LdbxSahb
2017-02-13 17:02:43 -08:00
Cameron McCormack
334e0fe231 Bug 1334735 - Part 1: Move need style/flush flags from document to pres shell. r=bz
MozReview-Commit-ID: 2Amf9yGRiJA
2017-02-10 10:42:27 +08:00
Bobby Holley
b77d94bc0f Bug 1333183 - Prime the root element cache before the servo traversal. r=emilio 2017-02-08 17:04:47 -08:00
Kirk Steuber
08b3810f6c Bug 1336714 - Added a null check to the GetParentDocument call in nsDocument::ComputeFlashClassification. Change nsDocument::GetAllowPlugins to return result rather than using unnecessary outparam. nsPluginArray::AllowPlugins changed to call the GetAllowPlugins method on the inner window's document rather than on the docshell's mContentViewer's document. r=bsmedberg,bz
MozReview-Commit-ID: Crx9v8OBKKq
2017-02-06 12:47:00 -08:00
Kearwood Gilbert
18cd99f71f Bug 1325428 - Disable bfcache for WebVR pages r=smaug
MozReview-Commit-ID: fymOSOEoDC
2017-02-03 16:49:15 -08:00
Alastor Wu
9b3c33d251 Bug 1319771 - part2 : resume foreground window if it was still be blocked. r=baku
In previous patch, we modify the behavior of nsDocument, now it would only resume
window when document has active media components.

However, it causes another issue. If the tab really goes to foreground, but
there is no active media component, the tab would still be blocked and it won't
be resumed anymore.

Therefore, we need to resume it by ourself if the tab is on the foreground but
doesn't be resumed yet.

MozReview-Commit-ID: EdnQ7sRkSJK
2017-02-03 10:50:07 +08:00
Alastor Wu
703e4c34c8 Bug 1319771 - part1 : only resume the window when there has active media components. r=baku
For the first pinned tab, it would be set to visible first and then set to
invisible if there exists other tabs after restarting the whole browser.

If the tab is set to visible, we would activate the media component (set the
|mMediaSuspended| in outer window to none-suspend). In this case, the first
pinned tab would be set to visible briefly, but it doesn't mean the tab is in
the foreground, it's just how DOM manage the tab's visibility.

In that moment, none of the media component has been created yet. Therefore, we
would only activate the media component after the audio channel service exists.

MozReview-Commit-ID: 1FgdMq84yWX
2017-02-03 10:48:38 +08:00
Wes Kocher
0b30c5ef89 Merge m-c to autoland, a=merge
MozReview-Commit-ID: 8vGne2PAweU
2017-02-02 16:45:43 -08:00
Wes Kocher
5a055d83d9 Merge inbound to central, a=merge
MozReview-Commit-ID: 9bhCPrArK3P
2017-02-02 16:39:24 -08:00