Bug 1287007 - Remove dead code r=billm

MozReview-Commit-ID: LtuKY5DjB68

--HG--
extra : rebase_source : d79d45cef78822977766f67f2172239d523a7182
This commit is contained in:
Rob Wu 2016-09-06 15:50:50 -07:00
parent 0baf41ff20
commit 2b7962648c
2 changed files with 3 additions and 15 deletions

View File

@ -190,9 +190,7 @@ class ExtensionContext extends BaseContext {
apiManager.global.initializeBackgroundPage(contentWindow);
}
if (this.externallyVisible) {
this.extension.views.add(this);
}
this.extension.views.add(this);
}
get cloneScope() {
@ -210,10 +208,6 @@ class ExtensionContext extends BaseContext {
}
}
get externallyVisible() {
return true;
}
// Called when the extension shuts down.
shutdown() {
this.unload();
@ -231,10 +225,7 @@ class ExtensionContext extends BaseContext {
super.unload();
this.childManager.close();
if (this.externallyVisible) {
this.extension.views.delete(this);
}
this.extension.views.delete(this);
}
}

View File

@ -26,10 +26,8 @@ function BackgroundPage(options, extension) {
this.extension = extension;
this.page = options.page || null;
this.isGenerated = !!options.scripts;
this.contentWindow = null;
this.windowlessBrowser = null;
this.webNav = null;
this.context = null;
}
BackgroundPage.prototype = {
@ -91,10 +89,9 @@ BackgroundPage.prototype = {
});
});
// TODO(robwu): This is not webext-oop compatible.
this.webNav = browser.docShell.QueryInterface(Ci.nsIWebNavigation);
let window = this.webNav.document.defaultView;
this.contentWindow = window;
// Set the add-on's main debugger global, for use in the debugger