зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1333477: Part 2 - Remove "browser" environment from ESLint settings. r=aswan
MozReview-Commit-ID: LCxI6JVp7Xo --HG-- extra : rebase_source : d0fc6519f3b6872f76a9df533f3eddf1352c2559 extra : histedit_source : 790c0f2322f2b3a3d35b8bf6d7b3f7b705f33fcd%2Cdae80b78b03f25f165f1fc575667df394a43b572
This commit is contained in:
Родитель
ecf57d28a0
Коммит
3d8483182d
|
@ -3,6 +3,10 @@
|
|||
module.exports = { // eslint-disable-line no-undef
|
||||
"extends": "../../.eslintrc.js",
|
||||
|
||||
"env": {
|
||||
"browser": false,
|
||||
},
|
||||
|
||||
"globals": {
|
||||
"Cc": true,
|
||||
"Ci": true,
|
||||
|
|
|
@ -17,6 +17,10 @@ const Cu = Components.utils;
|
|||
const Cr = Components.results;
|
||||
const global = this;
|
||||
|
||||
/* globals atob, btoa */
|
||||
|
||||
Cu.importGlobalProperties(["atob", "btoa"]);
|
||||
|
||||
Cu.import("resource://gre/modules/AppConstants.jsm");
|
||||
const KINTO_PROD_SERVER_URL = "https://webextensions.settings.services.mozilla.com/v1";
|
||||
const KINTO_DEFAULT_SERVER_URL = KINTO_PROD_SERVER_URL;
|
||||
|
|
|
@ -54,12 +54,12 @@ function frameScript() {
|
|||
Components.utils.import("resource://gre/modules/ExtensionContent.jsm");
|
||||
|
||||
ExtensionContent.init(this);
|
||||
addEventListener("unload", () => {
|
||||
this.addEventListener("unload", () => { // eslint-disable-line mozilla/balanced-listeners
|
||||
ExtensionContent.uninit(this);
|
||||
});
|
||||
}
|
||||
|
||||
const FRAME_SCRIPT = `data:text/javascript,(${frameScript}).call(this)`;
|
||||
const FRAME_SCRIPT = `data:text/javascript,(${encodeURI(frameScript)}).call(this)`;
|
||||
|
||||
|
||||
const XUL_URL = "data:application/vnd.mozilla.xul+xml;charset=utf-8," + encodeURI(
|
||||
|
|
|
@ -26,7 +26,7 @@ const {
|
|||
stylesheetMap,
|
||||
} = ExtensionUtils;
|
||||
|
||||
/* globals addMessageListener, content, docShell, sendAsyncMessage */
|
||||
/* globals addMessageListener, addEventListener, content, docShell, removeEventListener, sendAsyncMessage */
|
||||
|
||||
// Minimum time between two resizes.
|
||||
const RESIZE_TIMEOUT = 100;
|
||||
|
|
|
@ -13,6 +13,9 @@ XPCOMUtils.defineLazyPreferenceGetter(this, "redirectDomain",
|
|||
"extensions.webextensions.identity.redirectDomain");
|
||||
|
||||
let CryptoHash = CC("@mozilla.org/security/hash;1", "nsICryptoHash", "initWithString");
|
||||
|
||||
/* globals URL, XMLHttpRequest */
|
||||
|
||||
Cu.importGlobalProperties(["URL", "XMLHttpRequest", "TextEncoder"]);
|
||||
|
||||
Cu.import("resource://gre/modules/ExtensionUtils.jsm");
|
||||
|
|
|
@ -4,6 +4,7 @@ module.exports = { // eslint-disable-line no-undef
|
|||
"extends": "../../../../../testing/mochitest/mochitest.eslintrc.js",
|
||||
|
||||
"env": {
|
||||
"browser": true,
|
||||
"webextensions": true,
|
||||
},
|
||||
|
||||
|
|
|
@ -6,4 +6,8 @@ module.exports = { // eslint-disable-line no-undef
|
|||
"globals": {
|
||||
"browser": false,
|
||||
},
|
||||
|
||||
"env": {
|
||||
"browser": true,
|
||||
}
|
||||
};
|
||||
|
|
Загрузка…
Ссылка в новой задаче