Bug 1524688: Part 62 - Convert ContentDispatchChooser to static registration. r=mconley

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

--HG--
rename : toolkit/mozapps/handling/nsContentDispatchChooser.js => toolkit/mozapps/handling/ContentDispatchChooser.jsm
extra : rebase_source : 9df1030519010ea67fba5b67362b74556e4ce5c3
This commit is contained in:
Kris Maglione 2019-01-30 13:23:34 -08:00
parent eacc156e72
commit 5cd486c019
7 changed files with 24 additions and 16 deletions

View File

@ -174,8 +174,6 @@
@RESPATH@/components/nsUpdateService.manifest
#endif
@RESPATH@/components/ProcessSingleton.manifest
@RESPATH@/components/nsContentDispatchChooser.manifest
@RESPATH@/components/nsContentDispatchChooser.js
@RESPATH@/components/HandlerService.manifest
@RESPATH@/components/HandlerService.js
#ifdef XP_MACOSX

View File

@ -243,7 +243,6 @@
@BINPATH@/components/BlocklistPrompt.js
@BINPATH@/components/BrowserCLH.js
@BINPATH@/components/ColorPicker.js
@BINPATH@/components/ContentDispatchChooser.js
@BINPATH@/components/ContentPermissionPrompt.js
@BINPATH@/components/ImageBlockingPolicy.js
@BINPATH@/components/DirectoryProvider.js

View File

@ -14,7 +14,6 @@ DIRS += [
'modules',
'mozapps/downloads',
'mozapps/extensions',
'mozapps/handling',
'mozapps/preferences',
'pluginproblem',
'profile',
@ -37,6 +36,8 @@ if CONFIG['MOZ_MAINTENANCE_SERVICE']:
DIRS += ['xre']
if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'android':
DIRS += ['mozapps/handling']
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gtk3':
DIRS += ['system/unixproxy']
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':

View File

@ -4,7 +4,6 @@
// Constants
const {XPCOMUtils} = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
const {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");
const CONTENT_HANDLING_URL = "chrome://mozapps/content/handling/dialog.xul";
@ -67,8 +66,4 @@ nsContentDispatchChooser.prototype =
QueryInterface: ChromeUtils.generateQI([Ci.nsIContentDispatchChooser]),
};
// Module
var components = [nsContentDispatchChooser];
this.NSGetFactory = XPCOMUtils.generateNSGetFactory(components);
var EXPORTED_SYMBOLS = ["nsContentDispatchChooser"];

View File

@ -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': '{e35d5067-95bc-4029-8432-e8f1e431148d}',
'contract_ids': ['@mozilla.org/content-dispatch-chooser;1'],
'jsm': 'resource://gre/modules/ContentDispatchChooser.jsm',
'constructor': 'nsContentDispatchChooser',
},
]

View File

@ -7,9 +7,12 @@
with Files('**'):
BUG_COMPONENT = ('Firefox', 'File Handling')
EXTRA_COMPONENTS += [
'nsContentDispatchChooser.js',
'nsContentDispatchChooser.manifest',
EXTRA_JS_MODULES += [
'ContentDispatchChooser.jsm',
]
JAR_MANIFESTS += ['jar.mn']
XPCOM_MANIFESTS += [
'components.conf',
]
JAR_MANIFESTS += ['jar.mn']

View File

@ -1,2 +0,0 @@
component {e35d5067-95bc-4029-8432-e8f1e431148d} nsContentDispatchChooser.js
contract @mozilla.org/content-dispatch-chooser;1 {e35d5067-95bc-4029-8432-e8f1e431148d}