Bug 634435: Add a property to expose the current pushState-state. r=jlebar a=beltzner
This commit is contained in:
@@ -6074,7 +6074,7 @@ nsDocShell::EndPageLoad(nsIWebProgress * aProgress,
|
||||
if (!mEODForCurrentDocument && mContentViewer) {
|
||||
// Set the pending state object which will be returned to the page in
|
||||
// the popstate event.
|
||||
SetDocPendingStateObj(mLSHE);
|
||||
SetDocCurrentStateObj(mLSHE);
|
||||
|
||||
mIsExecutingOnLoadHandler = PR_TRUE;
|
||||
rv = mContentViewer->LoadComplete(aStatus);
|
||||
@@ -7766,7 +7766,7 @@ nsDocShell::SetupNewViewer(nsIContentViewer * aNewViewer)
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsDocShell::SetDocPendingStateObj(nsISHEntry *shEntry)
|
||||
nsDocShell::SetDocCurrentStateObj(nsISHEntry *shEntry)
|
||||
{
|
||||
nsresult rv;
|
||||
|
||||
@@ -7782,7 +7782,7 @@ nsDocShell::SetDocPendingStateObj(nsISHEntry *shEntry)
|
||||
// empty string.
|
||||
}
|
||||
|
||||
document->SetPendingStateObject(stateData);
|
||||
document->SetCurrentStateObject(stateData);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
@@ -8432,7 +8432,7 @@ nsDocShell::InternalLoad(nsIURI * aURI,
|
||||
doc->SetDocumentURI(newURI);
|
||||
}
|
||||
|
||||
SetDocPendingStateObj(mOSHE);
|
||||
SetDocCurrentStateObj(mOSHE);
|
||||
|
||||
// Dispatch the popstate and hashchange events, as appropriate.
|
||||
nsCOMPtr<nsPIDOMWindow> window = do_QueryInterface(mScriptGlobal);
|
||||
|
||||
Reference in New Issue
Block a user