Skip to content

Commit

Permalink
Backed out changeset e7c2fe034f25 (bug 1356816) for mochitest bustage
Browse files Browse the repository at this point in the history
UltraBlame original commit: 1f030c7f4fc574643c9b200ef06014f608da1b16
  • Loading branch information
marco-c committed Oct 1, 2019
1 parent 3807239 commit bacc54b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
10 changes: 10 additions & 0 deletions toolkit/components/extensions/Extension.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -667,6 +667,8 @@ this.ExtensionData = class {
}
};

let _browserUpdated = false;

const PROXIED_EVENTS = new Set(["test-harness-message", "add-permissions", "remove-permissions"]);


Expand Down Expand Up @@ -743,6 +745,14 @@ this.Extension = class extends ExtensionData {

}

static set browserUpdated(updated) {
_browserUpdated = updated;
}

static get browserUpdated() {
return _browserUpdated;
}

static generateXPI(data) {
return ExtensionTestCommon.generateXPI(data);
}
Expand Down
4 changes: 1 addition & 3 deletions toolkit/components/extensions/ext-runtime.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

XPCOMUtils.defineLazyModuleGetter(this, "AddonManager",
"resource://gre/modules/AddonManager.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "AddonManagerPrivate",
"resource://gre/modules/AddonManager.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "Extension",
"resource://gre/modules/Extension.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "ExtensionManagement",
Expand Down Expand Up @@ -36,7 +34,7 @@ this.runtime = class extends ExtensionAPI {
let listener = () => {
switch (extension.startupReason) {
case "APP_STARTUP":
if (AddonManagerPrivate.browserUpdated) {
if (Extension.browserUpdated) {
fire.sync({reason: "browser_update"});
}
break;
Expand Down
7 changes: 1 addition & 6 deletions toolkit/mozapps/extensions/AddonManager.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,6 @@ var gShutdownBarrier = null;
var gRepoShutdownState = "";
var gShutdownInProgress = false;
var gPluginPageListener = null;
var gBrowserUpdated = null;



Expand Down Expand Up @@ -816,7 +815,7 @@ var AddonManagerInternal = {
appChanged = Services.appinfo.version != oldAppVersion;
} catch (e) { }

gBrowserUpdated = appChanged;
Extension.browserUpdated = appChanged;

let oldPlatformVersion = Services.prefs.getCharPref(PREF_EM_LAST_PLATFORM_VERSION, "");

Expand Down Expand Up @@ -3099,10 +3098,6 @@ this.AddonManagerPrivate = {
AddonManagerInternal.startup();
},

get browserUpdated() {
return gBrowserUpdated;
},

registerProvider(aProvider, aTypes) {
AddonManagerInternal.registerProvider(aProvider, aTypes);
},
Expand Down

0 comments on commit bacc54b

Please sign in to comment.