Bug 1478305 - Remove unnecessary imports and fix ESLint warnings about unused variables for browser/. r=jaws

MozReview-Commit-ID: 1vHR6ixePkN

--HG--
extra : rebase_source : 8f9a322d1ff075ab56b81f8710df5d841839865b
This commit is contained in:
Mark Banner 2018-07-30 10:27:36 +01:00
Родитель 3fa6f1c498
Коммит 8d235f8e45
8 изменённых файлов: 4 добавлений и 16 удалений

Просмотреть файл

@ -1,7 +1,5 @@
"use strict";
/* exported gProfD, promiseMigration, registerFakePath, URL */
ChromeUtils.import("resource:///modules/MigrationUtils.jsm");
ChromeUtils.import("resource://gre/modules/LoginHelper.jsm");
ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
@ -15,10 +13,8 @@ ChromeUtils.import("resource://testing-common/PlacesTestUtils.jsm");
XPCOMUtils.defineLazyGlobalGetters(this, [ "URL" ]);
// eslint-disable-next-line no-unused-vars
ChromeUtils.defineModuleGetter(this, "FileUtils",
"resource://gre/modules/FileUtils.jsm");
// eslint-disable-next-line no-unused-vars
ChromeUtils.defineModuleGetter(this, "Sqlite",
"resource://gre/modules/Sqlite.jsm");

Просмотреть файл

@ -19,7 +19,6 @@
/* eslint-env mozilla/frame-script */
ChromeUtils.import("resource://gre/modules/Services.jsm");
ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
ChromeUtils.defineModuleGetter(this, "FormAutofill",

Просмотреть файл

@ -126,10 +126,11 @@ function startup(data) {
Services.mm.addMessageListener("FormAutoComplete:MaybeOpenPopup", onMaybeOpenPopup);
formAutofillParent.init().catch(Cu.reportError);
/* exported FormAutofillContent */
/* eslint-disable no-unused-vars */
Services.ppmm.loadProcessScript("data:,new " + function() {
ChromeUtils.import("resource://formautofill/FormAutofillContent.jsm");
}, true);
/* eslint-enable no-unused-vars */
Services.mm.loadFrameScript("chrome://formautofill/content/FormAutofillFrameScript.js", true);
}

Просмотреть файл

@ -7,6 +7,7 @@
"use strict";
// eslint-disable-next-line no-unused-vars
ChromeUtils.import("resource://formautofill/FormAutofill.jsm");
ChromeUtils.import("resource://formautofill/FormAutofillUtils.jsm");

Просмотреть файл

@ -10,7 +10,6 @@ const EDIT_ADDRESS_URL = "chrome://formautofill/content/editAddress.xhtml";
const EDIT_CREDIT_CARD_URL = "chrome://formautofill/content/editCreditCard.xhtml";
ChromeUtils.import("resource://gre/modules/Services.jsm");
ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
ChromeUtils.import("resource://formautofill/FormAutofill.jsm");
ChromeUtils.defineModuleGetter(this, "CreditCard",

Просмотреть файл

@ -2,25 +2,18 @@
* Provides infrastructure for automated formautofill components tests.
*/
/* exported getTempFile, loadFormAutofillContent, runHeuristicsTest, sinon,
* initProfileStorage, getSyncChangeCounter, objectMatches, bootstrapURI
*/
"use strict";
ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
ChromeUtils.import("resource://gre/modules/Services.jsm");
ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
ChromeUtils.import("resource://gre/modules/ObjectUtils.jsm");
ChromeUtils.import("resource://gre/modules/FormLikeFactory.jsm");
ChromeUtils.import("resource://testing-common/FileTestUtils.jsm");
ChromeUtils.import("resource://testing-common/MockDocument.jsm");
ChromeUtils.import("resource://testing-common/TestUtils.jsm");
// eslint-disable-next-line no-unused-vars
ChromeUtils.defineModuleGetter(this, "DownloadPaths",
"resource://gre/modules/DownloadPaths.jsm");
// eslint-disable-next-line no-unused-vars
ChromeUtils.defineModuleGetter(this, "FileUtils",
"resource://gre/modules/FileUtils.jsm");

Просмотреть файл

@ -1,6 +1,7 @@
"use strict";
/* global AddressResult, CreditCardResult */
// eslint-disable-next-line no-unused-vars
ChromeUtils.import("resource://formautofill/ProfileAutoCompleteResult.jsm");
let matchingProfiles = [{

Просмотреть файл

@ -19,8 +19,6 @@ var EXPORTED_SYMBOLS = ["PdfJsRegistration"];
const Cm = Components.manager;
ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
ChromeUtils.defineModuleGetter(this, "PdfStreamConverter",
"resource://pdf.js/PdfStreamConverter.jsm");