mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-28 23:31:56 +00:00
Bug 903293 - Remote browser constructors shouldn't try to initialize session history; r=felipe
This commit is contained in:
parent
5a99f8d881
commit
69588e07bf
@ -669,7 +669,7 @@
|
||||
<constructor>
|
||||
<![CDATA[
|
||||
try {
|
||||
if (!this.hasAttribute("disablehistory")) {
|
||||
if (this.docShell && !this.hasAttribute("disablehistory")) {
|
||||
var os = Components.classes["@mozilla.org/observer-service;1"]
|
||||
.getService(Components.interfaces.nsIObserverService);
|
||||
os.addObserver(this, "browser:purge-session-history", false);
|
||||
@ -678,7 +678,7 @@
|
||||
Components.classes["@mozilla.org/browser/shistory;1"]
|
||||
.createInstance(Components.interfaces.nsISHistory);
|
||||
// enable global history if we weren't told otherwise
|
||||
if (this.docShell && !this.hasAttribute("disableglobalhistory"))
|
||||
if (!this.hasAttribute("disableglobalhistory"))
|
||||
this.docShell.useGlobalHistory = true;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user