зеркало из https://github.com/mozilla/pjs.git
bug 294524 - reload buttons don't work after sanitizing, patch by Teune van Steeg <twanno@lycos.nl>, r=me, a=asa
This commit is contained in:
Родитель
3456bb0fa9
Коммит
135cf1adae
|
@ -622,6 +622,14 @@
|
|||
if (aTopic != "browser:purge-session-history")
|
||||
return;
|
||||
|
||||
// place the entry at current index at the end of the history list, so it won't get removed
|
||||
if (this.sessionHistory.index < this.sessionHistory.count - 1) {
|
||||
var indexEntry = this.sessionHistory.getEntryAtIndex(this.sessionHistory.index, false);
|
||||
this.sessionHistory.QueryInterface(Components.interfaces.nsISHistoryInternal);
|
||||
indexEntry.QueryInterface(Components.interfaces.nsISHEntry);
|
||||
this.sessionHistory.addEntry(indexEntry, true);
|
||||
}
|
||||
|
||||
var purge = this.sessionHistory.count;
|
||||
if (this.currentURI != "about:blank")
|
||||
--purge; // Don't remove the page the user's staring at from shistory
|
||||
|
|
Загрузка…
Ссылка в новой задаче