Skip to content

Commit bb337a8

Browse files
committed
Bug 1489301 - Part 5: Expose all System-only objects on Window, r=bzbarsky
There is a limited number of these, and this allows me to completely remove mention of the 'System' global. In the future System-only exposure could be achieved using a [Func] enabler. Differential Revision: https://phabricator.services.mozilla.com/D9400
1 parent 0562b4b commit bb337a8

5 files changed

+6
-6
lines changed

dom/chrome-webidl/ChannelWrapper.webidl

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ enum MozContentPolicyType {
4141
* A thin wrapper around nsIChannel and nsIHttpChannel that allows JS
4242
* callers to access them without XPConnect overhead.
4343
*/
44-
[ChromeOnly, Exposed=System]
44+
[ChromeOnly, Exposed=Window]
4545
interface ChannelWrapper : EventTarget {
4646
/**
4747
* Returns the wrapper instance for the given channel. The same wrapper is

dom/chrome-webidl/MozDocumentObserver.webidl

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ callback interface MozDocumentCallback {
99
void onPreloadDocument(MozDocumentMatcher matcher, LoadInfo loadInfo);
1010
};
1111

12-
[ChromeOnly, Constructor(MozDocumentCallback callbacks), Exposed=System]
12+
[ChromeOnly, Constructor(MozDocumentCallback callbacks), Exposed=Window]
1313
interface MozDocumentObserver {
1414
[Throws]
1515
void observe(sequence<MozDocumentMatcher> matchers);

dom/chrome-webidl/WebExtensionContentScript.webidl

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ interface WindowProxy;
99
typedef (MatchPatternSet or sequence<DOMString>) MatchPatternSetOrStringSequence;
1010
typedef (MatchGlob or DOMString) MatchGlobOrString;
1111

12-
[Constructor(MozDocumentMatcherInit options), ChromeOnly, Exposed=System]
12+
[Constructor(MozDocumentMatcherInit options), ChromeOnly, Exposed=Window]
1313
interface MozDocumentMatcher {
1414
/**
1515
* Returns true if the script's match and exclude patterns match the given
@@ -132,7 +132,7 @@ enum ContentScriptRunAt {
132132
"document_idle",
133133
};
134134

135-
[Constructor(WebExtensionPolicy extension, WebExtensionContentScriptInit options), ChromeOnly, Exposed=System]
135+
[Constructor(WebExtensionPolicy extension, WebExtensionContentScriptInit options), ChromeOnly, Exposed=Window]
136136
interface WebExtensionContentScript : MozDocumentMatcher {
137137
/**
138138
* The earliest point in the load cycle at which this script should run. For

dom/chrome-webidl/WebExtensionPolicy.webidl

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ callback WebExtensionLocalizeCallback = DOMString (DOMString unlocalizedText);
1111
* Defines the platform-level policies for a WebExtension, including its
1212
* permissions and the characteristics of its moz-extension: URLs.
1313
*/
14-
[Constructor(WebExtensionInit options), ChromeOnly, Exposed=System]
14+
[Constructor(WebExtensionInit options), ChromeOnly, Exposed=Window]
1515
interface WebExtensionPolicy {
1616
/**
1717
* The add-on's internal ID, as specified in its manifest.json file or its

dom/webidl/AddonManager.webidl

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ interface AddonManager : EventTarget {
8282
readonly attribute boolean permissionPromptsEnabled;
8383
};
8484

85-
[ChromeOnly,Exposed=System,HeaderFile="mozilla/AddonManagerWebAPI.h"]
85+
[ChromeOnly,Exposed=Window,HeaderFile="mozilla/AddonManagerWebAPI.h"]
8686
interface AddonManagerPermissions {
8787
static boolean isHostPermitted(DOMString host);
8888
};

0 commit comments

Comments
 (0)