Bug 1524688: Part 21 - Convert XULStore to static registration. r=mconley
☠☠ backed out by 3b1b94e39795 ☠ ☠
authorKris Maglione <maglione.k@gmail.com>
Tue, 29 Jan 2019 21:14:53 -0800
changeset 458994 4cbbb367ba0b
parent 458993 4ed0cf6be580
child 458995 dd89eb7e9b0d
push id111909
push usermaglione.k@gmail.com
push dateThu, 14 Feb 2019 02:30:40 +0000
treeherdermozilla-inbound@81dc12cc9257 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmconley
bugs1524688
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1524688: Part 21 - Convert XULStore to static registration. r=mconley
browser/installer/package-manifest.in
mobile/android/installer/package-manifest.in
toolkit/components/xulstore/XULStore.js
toolkit/components/xulstore/XULStore.jsm
toolkit/components/xulstore/XULStore.manifest
toolkit/components/xulstore/components.conf
toolkit/components/xulstore/moz.build
--- a/browser/installer/package-manifest.in
+++ b/browser/installer/package-manifest.in
@@ -239,18 +239,16 @@
 @RESPATH@/components/CaptivePortalDetectComponents.manifest
 @RESPATH@/components/captivedetect.js
 @RESPATH@/components/servicesComponents.manifest
 @RESPATH@/components/servicesSettings.manifest
 @RESPATH@/components/RemoteSettingsComponents.js
 @RESPATH@/components/cryptoComponents.manifest
 @RESPATH@/components/TelemetryStartup.js
 @RESPATH@/components/TelemetryStartup.manifest
-@RESPATH@/components/XULStore.js
-@RESPATH@/components/XULStore.manifest
 @RESPATH@/components/recording-cmdline.js
 @RESPATH@/components/recording-cmdline.manifest
 @RESPATH@/components/htmlMenuBuilder.js
 @RESPATH@/components/htmlMenuBuilder.manifest
 
 @RESPATH@/components/NotificationStorage.js
 @RESPATH@/components/NotificationStorage.manifest
 @RESPATH@/components/Push.manifest
--- a/mobile/android/installer/package-manifest.in
+++ b/mobile/android/installer/package-manifest.in
@@ -163,18 +163,16 @@
 @BINPATH@/components/servicesSettings.manifest
 @BINPATH@/components/RemoteSettingsComponents.js
 
 #ifndef MOZ_GECKOVIEW_JAR
 @BINPATH@/components/TelemetryStartup.js
 @BINPATH@/components/TelemetryStartup.manifest
 #endif
 
-@BINPATH@/components/XULStore.js
-@BINPATH@/components/XULStore.manifest
 @BINPATH@/components/htmlMenuBuilder.js
 @BINPATH@/components/htmlMenuBuilder.manifest
 
 @BINPATH@/components/CaptivePortalDetectComponents.manifest
 @BINPATH@/components/captivedetect.js
 
 #if defined(ENABLE_TESTS) && defined(MOZ_DEBUG)
 @BINPATH@/components/TestInterfaceJS.js
rename from toolkit/components/xulstore/XULStore.js
rename to toolkit/components/xulstore/XULStore.jsm
--- a/toolkit/components/xulstore/XULStore.js
+++ b/toolkit/components/xulstore/XULStore.jsm
@@ -300,9 +300,9 @@ nsStringEnumerator.prototype = {
   },
   getNext() {
     if (!this.hasMore())
       throw Cr.NS_ERROR_NOT_AVAILABLE;
     return this._items[this._nextIndex++];
   },
 };
 
-this.NSGetFactory = XPCOMUtils.generateNSGetFactory([XULStore]);
+var EXPORTED_SYMBOLS = ["XULStore"];
deleted file mode 100644
--- a/toolkit/components/xulstore/XULStore.manifest
+++ /dev/null
@@ -1,2 +0,0 @@
-component {6f46b6f4-c8b1-4bd4-a4fa-9ebbed0753ea} XULStore.js
-contract @mozilla.org/xul/xulstore;1 {6f46b6f4-c8b1-4bd4-a4fa-9ebbed0753ea}
new file mode 100644
--- /dev/null
+++ b/toolkit/components/xulstore/components.conf
@@ -0,0 +1,14 @@
+# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
+# vim: set filetype=python:
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+Classes = [
+    {
+        'cid': '{6f46b6f4-c8b1-4bd4-a4fa-9ebbed0753ea}',
+        'contract_ids': ['@mozilla.org/xul/xulstore;1'],
+        'jsm': 'resource://gre/modules/XULStore.jsm',
+        'constructor': 'XULStore',
+    },
+]
--- a/toolkit/components/xulstore/moz.build
+++ b/toolkit/components/xulstore/moz.build
@@ -11,12 +11,15 @@ MOCHITEST_CHROME_MANIFESTS += ['tests/ch
 XPCSHELL_TESTS_MANIFESTS += ['tests/xpcshell/xpcshell.ini']
 
 XPIDL_SOURCES += [
     'nsIXULStore.idl',
 ]
 
 XPIDL_MODULE = 'toolkit_xulstore'
 
-EXTRA_COMPONENTS += [
-    'XULStore.js',
-    'XULStore.manifest',
+EXTRA_JS_MODULES += [
+    'XULStore.jsm',
 ]
+
+XPCOM_MANIFESTS += [
+    'components.conf',
+]