mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 342635 - wrong scroll behaviour after loading new page while session restoring. r=dietrich
This commit is contained in:
parent
fd23220e6f
commit
78649b88bb
@ -1785,6 +1785,10 @@ SessionStoreService.prototype = {
|
||||
}
|
||||
}
|
||||
|
||||
// don't restore text data and scrolling state if the user has navigated
|
||||
// away before the loading completed (except for in-page navigation)
|
||||
if (!this.__SS_restore_data.url || this.currentURI.spec.replace(/#.*/, "") ==
|
||||
this.__SS_restore_data.url.replace(/#.*/, "")) {
|
||||
var content = aEvent.originalTarget.defaultView;
|
||||
if (this.currentURI.spec == "about:config") {
|
||||
// unwrap the document for about:config because otherwise the properties
|
||||
@ -1797,6 +1801,7 @@ SessionStoreService.prototype = {
|
||||
var event = this.ownerDocument.createEvent("Events");
|
||||
event.initEvent("SSTabRestored", true, false);
|
||||
this.__SS_restore_tab.dispatchEvent(event);
|
||||
}
|
||||
|
||||
this.removeEventListener("load", this.__SS_restore, true);
|
||||
delete this.__SS_restore_data;
|
||||
|
Loading…
Reference in New Issue
Block a user