Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1065)

Unified Diff: Source/core/frame/DOMWindow.cpp

Issue 136463002: Don't fire popstate event on initial document load (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: fix replacestate-in-iframe test Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/http/tests/navigation/redirect-on-reload-updates-history-item-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/frame/DOMWindow.cpp
diff --git a/Source/core/frame/DOMWindow.cpp b/Source/core/frame/DOMWindow.cpp
index 1912f24d0c41b58b5b0ad5c2ba45271db57635ed..e52015a91aa505202e0d1b305712bf8d06a1cea1 100644
--- a/Source/core/frame/DOMWindow.cpp
+++ b/Source/core/frame/DOMWindow.cpp
@@ -450,7 +450,8 @@ void DOMWindow::documentWasClosed()
{
dispatchWindowLoadEvent();
enqueuePageshowEvent(PageshowEventNotPersisted);
- enqueuePopstateEvent(m_pendingStateObject ? m_pendingStateObject.release() : SerializedScriptValue::nullValue());
+ if (m_pendingStateObject)
+ enqueuePopstateEvent(m_pendingStateObject.release());
}
void DOMWindow::enqueuePageshowEvent(PageshowEventPersistence persisted)
« no previous file with comments | « LayoutTests/http/tests/navigation/redirect-on-reload-updates-history-item-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698