Bug 422543 - part 1 - make session history support multiple listeners; r=smaug

This commit is contained in:
Tim Taubert
2012-09-20 16:41:18 +02:00
parent c605a37930
commit 603baac80c
4 changed files with 104 additions and 86 deletions

View File

@@ -4454,13 +4454,9 @@ nsDocShell::Reload(uint32_t aReloadFlags)
nsCOMPtr<nsISHistory> rootSH;
rv = GetRootSessionHistory(getter_AddRefs(rootSH));
nsCOMPtr<nsISHistoryInternal> shistInt(do_QueryInterface(rootSH));
bool canReload = true;
bool canReload = true;
if (rootSH) {
nsCOMPtr<nsISHistoryListener> listener;
shistInt->GetListener(getter_AddRefs(listener));
if (listener) {
listener->OnHistoryReload(mCurrentURI, aReloadFlags, &canReload);
}
shistInt->NotifyOnHistoryReload(mCurrentURI, aReloadFlags, &canReload);
}
if (!canReload)