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

461 Коммитов

Автор SHA1 Сообщение Дата
Kris Maglione 0c6cd02ae1 Bug 1483664: Part 0 - Dispatch pagehide/pageshow to all system group listeners on frameloader swap. r=smaug,mconley
Having to add pagehide/pageshow listeners to the chrome event target is a
serious inconvience for the use cases of this bug. Dispatching to system group
listeners has approximately the same effect as the old code, but is much
easier for window-bound code to handle.

--HG--
extra : rebase_source : d67c14e9ba91772d8a9dd82481120b34bdb551e0
2018-08-15 20:06:49 -07:00
Margareta Eliza Balazs 48299c8cd6 Merge inbound to mozilla-central. a=merge 2018-08-16 12:24:26 +03:00
Ehsan Akhgari 99d839224e Bug 1483604 - Part 2: Make all of the external consumers of nsContentUtils::StorageDisabledByAntiTracking() pass a channel if available; r=smaug 2018-08-15 19:00:52 -04:00
Ehsan Akhgari 0ef6860e9a Bug 1483604 - Part 1: Only call NotifyContentBlockingState() when the channel argument is non-null; r=smaug 2018-08-15 19:00:51 -04:00
Timothy Guan-tin Chien e1bae5c835 Bug 1431255 - Part I, Add dom.ua_widget.enabled pref and enable for Desktop Nightly only r=smaug
This would allow us to control this feature independently of the Shadow DOM pref.
The feature is only turned on when Shadow DOM is turned on.

MozReview-Commit-ID: 4g6BJigFUZs

--HG--
extra : rebase_source : d9e8ae0105fbe3dc18c9e163c612b9523db4c5b0
2018-07-06 08:46:43 +08:00
Ehsan Akhgari e01dca1048 Bug 1482988 - Handle null arguments in nsContentUtils::StorageDisabledByAntiTracking correctly; r=smaug 2018-08-13 16:27:44 -04:00
Andrea Marchesini d1e5833a37 Bug 1480780 - Merge the privacy.3rdpartystorage.enabled pref with the network.cookie.cookieBehavior pref; r=ehsan
This patch introduces a new cookie behavior policy called
BEHAVIOR_REJECT_TRACKER.  It also makes it possible to override that
behavior with cookie permissions similar to other cookie behaviors.
2018-08-13 16:01:16 -04:00
Jan de Mooij 2b60db1326 Bug 1472976 part 3 - Use JS::GetRealmPrincipals instead of JS_GetCompartmentPrincipals in nsContentUtils::ObjectPrincipal. r=smaug
This also removes an outdated comment, nsScriptSecurityManager::doGetObjectPrincipal was removed in bug 1464374.
2018-08-10 11:57:39 +02:00
Zibi Braniecki de06dc8116 Bug 1480673 - Add nsContentUtils::StringifyJSON. r=qdot
Add nsContentUtils::StringifyJSON.

Differential Revision: https://phabricator.services.mozilla.com/D2700

--HG--
extra : moz-landing-system : lando
2018-08-07 15:49:13 +00:00
Boris Zbarsky b421d6d7fb Bug 1479569 part 1. Add a ContentFrameMessageManager getter on nsIDocShell. r=kmag 2018-08-02 23:49:09 -04:00
Csoregi Natalia 08c950712e Backed out 3 changesets (bug 1479569) for devtools/client/responsive.html failures. CLOSED TREE
Backed out changeset e123d0aa911c (bug 1479569)
Backed out changeset b828a58404e5 (bug 1479569)
Backed out changeset 97041ef8f311 (bug 1479569)
2018-08-03 10:39:12 +03:00
Boris Zbarsky 0bfdfe4699 Bug 1479569 part 1. Add a ContentFrameMessageManager getter on nsIDocShell. r=kmag 2018-08-02 23:49:09 -04:00
Andreas Farre 1d151a57c8 Bug 1445659 - Create basic Browsing Context in Content Parent and Child. r=peterv
Add BrowsingContext to allow the tree structure of docshells to exist
in several processes simultaneously. This is a first step towards
allowing a tree structure preserving separation of docshells across
processes.

--HG--
extra : histedit_source : d3c7f6ab4b9ae76f170c126d669ebd570e52f348
2018-07-26 10:31:00 +03:00
Ehsan Akhgari 56cf43358e Bug 1478428 - Move the network.cookie.cookieBehavior pref to StaticPrefList.h; r=baku 2018-07-25 15:02:31 -04:00
Anny Gakhokidze f7f703b0e1 Bug 1473161 - Add missing bound check in nsContentUtils::DataTransferItemToImage. r=nika
MozReview-Commit-ID: 3dq5yWZwJiG
2018-07-17 19:02:51 -04:00
Brian Birtles a2a2e0da37 Bug 1475162 - Drop dom.animations-api.element-animate.enabled pref; r=bz
MozReview-Commit-ID: 5xKS30NmNbL

--HG--
extra : rebase_source : c34e8da8a04bee15d40c719db5e57037899cddd8
2018-07-12 15:56:05 +09:00
Andrea Marchesini 648c87fe95 Bug 1474651 - Grant storage access to 3rd party, tracking resource on window.open(), r=ehsan 2018-07-11 12:38:47 +02:00
shindli c1bbe21ac6 Backed out 2 changesets (bug 1474651) for lint failure in /builds/worker/checkouts/gecko/toolkit/components/antitracking/test/browser/popup.html:8:126 on a CLOSED TREE
Backed out changeset f05247b25d5e (bug 1474651)
Backed out changeset acee48580902 (bug 1474651)
2018-07-11 13:57:22 +03:00
Andrea Marchesini 06d77e5419 Bug 1474651 - Grant storage access to 3rd party, tracking resource on window.open(), r=ehsan 2018-07-11 12:38:47 +02:00
Andrea Marchesini e6921e1adc Bug 1469993 - Grant storage access to a 3rd party, tracking resource if a opened document has user-interaction - part 1 - storing first user interaction in a document with an opener window, r=ehsan 2018-07-10 10:09:58 +02:00
Margareta Eliza Balazs c37b51f523 Backed out 9 changesets (bug 1469993) for causing bustage in build/srcdom/base/nsGlobalWindowInner.cpp on a CLOSED TREE
Backed out changeset e89192032fe2 (bug 1469993)
Backed out changeset 4b261595099d (bug 1469993)
Backed out changeset 37182cfe869c (bug 1469993)
Backed out changeset 5b9870995c73 (bug 1469993)
Backed out changeset 55499fcd9738 (bug 1469993)
Backed out changeset 8c1c838d54ba (bug 1469993)
Backed out changeset 12b9c8bfa41f (bug 1469993)
Backed out changeset 04ab7d6c169a (bug 1469993)
Backed out changeset 53885d61244e (bug 1469993)
2018-07-10 11:32:34 +03:00
Andrea Marchesini 4322df2e13 Bug 1469993 - Grant storage access to a 3rd party, tracking resource if a opened document has user-interaction - part 1 - storing first user interaction in a document with an opener window, r=ehsan 2018-07-10 10:09:58 +02:00
Jan de Mooij 0f8c18a11f Bug 1473865 part 2 - Remove unused nsContentUtils::GetDocumentFromCaller. r=bz 2018-07-09 12:26:49 +02:00
Jeff Gilbert 5b753da289 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Emilio Cobos Álvarez c7d35aa526 Bug 1470930: Use enums for passing arguments for event dispatch. r=smaug
MozReview-Commit-ID: DsNuF7GAflJ
2018-06-26 18:22:06 +02:00
Andrea Marchesini 5b9437cad2 Bug 1461921 - Block storage access for third-parties on the tracking protection list - part 5 - Cookies, r=ehsan 2018-06-20 13:38:22 -04:00
Peter Van der Beken 0dbc31467c Bug 1451973 - Split off process from non-process message managers. r=bz.
Process and non-process managers have different script loader interfaces
(ProcessScriptLoader/GlobalProcessScriptLoader vs FrameScriptLoader). The WebIDL
conversion used the same interface for some process and
non-process managers, but because of the different script loader interfaces they really
should be using separate interfaces.

--HG--
rename : dom/base/ChromeMessageBroadcaster.cpp => dom/base/MessageBroadcaster.cpp
rename : dom/base/ChromeMessageBroadcaster.h => dom/base/MessageBroadcaster.h
rename : dom/base/ChromeMessageBroadcaster.cpp => dom/base/ParentProcessMessageManager.cpp
rename : dom/base/ChromeMessageBroadcaster.h => dom/base/ParentProcessMessageManager.h
rename : dom/base/ChromeMessageSender.cpp => dom/base/ProcessMessageManager.cpp
rename : dom/base/ChromeMessageSender.h => dom/base/ProcessMessageManager.h
extra : rebase_source : c9b0c543f9f367535919a6c6840e5ba038023112
extra : histedit_source : 7749f98e11e25423fcf414cc1f0415104343798a
2018-04-16 15:18:48 +02:00
Andreea Pavel bce82ccf82 Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2018-05-31 13:05:59 +03:00
Johann Hofmann ded334a8cb Bug 1444394 - Remove Element::UnsafeSetInnerHTML. r=bz,kmag
The last remaining user is already turned off and being removed
in bug 1444395 so that we can finally remove this unsafe code and
sleep a little better knowing that XSS through markup injections
will be impossible in chrome contexts.

MozReview-Commit-ID: KcZq8fRPiD4

--HG--
extra : rebase_source : 5def3abb50ed8f1b43e17072088e38a44394488b
2018-05-28 22:55:52 +02:00
Andrea Marchesini b0005ca281 Bug 1446921 - Get rid of 2 unused parameters in nsContentUtils::CanLoadImage, r=qdot 2018-05-30 21:21:17 +02:00
Boris Zbarsky bea3100e53 Bug 1455676 part 14. Remove most use of nsIDOMNode in dom/. r=qdot 2018-05-29 22:58:49 -04:00
Timothy Guan-tin Chien 9b93107cb5 Bug 1462703 - Upgrade the created element after callback runs r=smaug
nsContentUtils::NS_NewXULOrHTMLElement will call into
CustomElementRegisty::RegisterCallbackUpgradeElement, which keeps
the newly created element, allowing RunCustomElementCreationCallback
to upgrade them after the callback runs.

It is unclear if this changes the order of constructor executions,
but even so it should not affact our use case.

MozReview-Commit-ID: LWTn7B35aBv

--HG--
extra : rebase_source : 15382431f34dd887c14142ff47337e8d1eec74ef
extra : source : 47058a61951c2974514e41e316e5370cfa4f9d8b
2018-05-23 13:04:18 +08:00
Kristen Wright baaa671de8 Bug 1462138 - Part 2: Create a reporter for nsContentUtils string bundles. r=mccr8
Created new class 'nsContentUtilsReporter' which reports 'content-utils-string-bundles' allocations that are not a part of the reported StringBundleService bundles

--HG--
extra : rebase_source : f683ce214d634c9c6f169fafe5b5de12d3f3508a
2018-05-18 16:11:06 -07:00
Timothy Guan-tin Chien 08741f30ed Bug 1460962 - Support customized built-in element in XUL r=smaug
This patch enables us to specify a custom element type with |is| attribute
or property when creating a XUL element. Because non-dashed names are valid
custom element names in XUL (bug 1446247), other checks has to modified
accordingly.

The checks I am settling with are
1) Forbids the custom built-in element names to be a non-dashed name.
2) Forbids the custom built-in element to extend a dashed built-in element name.

This also ensures the custom built-in element types don't take on the same
name as the element name it extends.

MozReview-Commit-ID: GCQ9RnfvvrC

--HG--
extra : rebase_source : 2fa13742525d2107580d50872ff5b0fc42539498
extra : source : 2dc5513660d78a4de4801109140743ffc9297f71
2018-05-11 12:44:46 -07:00
Adrian Wielgosik c501e3beb0 Bug 1460940 - Clean up most remaining C++-side uses of nsIDOMDocument. r=bz
MozReview-Commit-ID: LKRnyDPNlle

--HG--
extra : rebase_source : a48b7c72a0f7ede38c91149a04d5de53987736f1
2018-05-11 19:46:15 +02:00
Olli Pettay 41366ba801 bug 1460794, ensure the right document is used for DOMSubtreeModified event, r=hsivonen
--HG--
extra : rebase_source : 1363016f0a6da8ca2f5be4d0a21e1ee0a6376c1c
2018-05-13 00:46:45 +03:00
Boris Zbarsky 2d13533f79 Bug 1460368. Remove now-unused nsContentUtils::GetClosestNonNativeAnonymousAncestor. r=heycam
This was used in the non-stylo style system, but that's all gone now.
2018-05-11 16:42:12 -04:00
Chris Peterson 71422dcaa9 Bug 1457813 - Part 2: Replace non-asserting NS_PRECONDITIONs with MOZ_ASSERTs. r=froydnj
s/NS_PRECONDITION/MOZ_ASSERT/ and reindent

MozReview-Commit-ID: KuUsnVe2h8L

--HG--
extra : source : c14655ab3df2c9b1465dd8102b9d25683359a37b
2018-04-28 12:50:58 -07:00
Eugen Sawin 8bee753352 Bug 1458687 - [1.0] Remove obsolete isUserTriggered argument in nsContentUtils::TriggerLink. r=smaug 2018-05-03 16:05:34 +02:00
Boris Zbarsky 914f11a6d2 Bug 1455674 part 10. Remove nsIDOMElement use from remaining dom/ xpidl files. r=qdot 2018-04-26 23:36:10 -04:00
Boris Zbarsky 0ba35d199f Bug 1455052 part 8. Stop using nsIDOMEvent in docshell and dom. r=masayuki
MozReview-Commit-ID: ASkuyN3xSwB
2018-04-20 12:55:30 -04:00
Boris Zbarsky b7f2b6976a Bug 1429903 part 3. Remove C++ uses of nsIDOMEventTarget. r=mccr8
MozReview-Commit-ID: 4NdssvnWn0H
2018-04-20 00:49:30 -04:00
Boris Zbarsky 38ecaf4bb7 Bug 1452183 part 3. Stop using nsIDOMDocumentFragment in C++. r=mccr8 2018-04-17 21:13:03 -04:00
Boris Zbarsky d49151ed50 Bug 1452183 part 1. Stop using nsIDOMDocumentFragment in IDL files. r=mccr8 2018-04-17 21:13:03 -04:00
Kyle Machulis 467ed19747 Bug 1453517 - Consolidate popup permission checks to nsContentUtils; r=bz
Permissions checks for popups were happening in nsIPopupWindowManager,
but that really only required a pref and perm check. The XPCOM
machinery around this isn't really needed, and the check was only
called from two places in content, so this fits in nsContentUtils.

MozReview-Commit-ID: 9x60x1BKWcr

--HG--
extra : rebase_source : d6e2dcfcae8310770eb209ccb42c96315511bb86
2018-04-11 16:18:20 -07:00
Karl Tomlinson 3481a11d87 bug 1328964 add CycleCollectedJSContext::IsSystemCaller() to make ThreadsafeIsSystemCaller() safe for worklets r=baku
MozReview-Commit-ID: Cg4OBbm5CwA

--HG--
extra : rebase_source : 9a113cf0f945bd48207e81f9fa08bcba1f35303c
2018-04-06 18:53:25 +12:00
Karl Tomlinson 2405fe930c bug 1328964 use nsContentUtils::GetCurrentJSContext() on all threads r=smaug
nsContentUtils::GetCurrentJSContextForThread() originally needed to use
workers::GetCurrentThreadJSContext() in
https://hg.mozilla.org/mozilla-central/rev/366a45b41539#l2.18
because CycleCollectedJS*()->Context() did not exist until
https://hg.mozilla.org/mozilla-central/rev/1a0cd542e1e9#l7.12

nsContentUtils::GetCurrentJSContext() is thread-safe since these changes:
https://hg.mozilla.org/mozilla-central/rev/e636c7186286#l3.12
https://hg.mozilla.org/mozilla-central/rev/c8029c072776#l2.12

MozReview-Commit-ID: 2f1eGS9uBBO

--HG--
extra : rebase_source : dad1d2084a63413c3975f9e7c66c6b06857c9f23
2018-04-09 12:11:18 +12:00
Brian Grinstead 6cb530800d Bug 1446247 - Pass namespace into IsCustomElementName to allow for non-dashed XUL elements;r=e7358d9c+590837,smaug
This will make it possible to migrate existing bindings without also needing to
mass-rewrite frontend code at the same time.

MozReview-Commit-ID: IBBqC4eeDDX

--HG--
extra : rebase_source : e901ac665208b3a683668c1bb33a26dcf479580c
2018-03-29 09:34:56 -07:00
Andreea Pavel d9706dbbb9 Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE 2018-04-06 13:26:13 +03:00
Andreea Pavel 9f9457503a Backed out changeset e220521c6ff6 (bug 1446247) on request a=backout r=smaug 2018-04-06 13:23:59 +03:00