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

Side by Side Diff: third_party/WebKit/Source/core/loader/FrameLoader.cpp

Issue 2628153002: PlzNavigate: Fix anchor-no-multiple-windows.html layout test. (Closed)
Patch Set: Update the shouldSendCompleteNotification() function to use the hasProvisionalNavigation() function Created 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights
3 * reserved. 3 * reserved.
4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
6 * (http://www.torchmobile.com/) 6 * (http://www.torchmobile.com/)
7 * Copyright (C) 2008 Alp Toker <alp@atoker.com> 7 * Copyright (C) 2008 Alp Toker <alp@atoker.com>
8 * Copyright (C) Research In Motion Limited 2009. All rights reserved. 8 * Copyright (C) Research In Motion Limited 2009. All rights reserved.
9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> 9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com>
10 * Copyright (C) 2011 Google Inc. All rights reserved. 10 * Copyright (C) 2011 Google Inc. All rights reserved.
(...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after
699 } 699 }
700 700
701 static bool shouldSendCompleteNotification(LocalFrame* frame, 701 static bool shouldSendCompleteNotification(LocalFrame* frame,
702 bool isNavigationHandledByClient) { 702 bool isNavigationHandledByClient) {
703 // FIXME: We might have already sent stop notifications and be re-completing. 703 // FIXME: We might have already sent stop notifications and be re-completing.
704 if (!frame->isLoading()) 704 if (!frame->isLoading())
705 return false; 705 return false;
706 // Only send didStopLoading() if there are no navigations in progress at all, 706 // Only send didStopLoading() if there are no navigations in progress at all,
707 // whether committed, provisional, or pending. 707 // whether committed, provisional, or pending.
708 return frame->loader().documentLoader()->sentDidFinishLoad() && 708 return frame->loader().documentLoader()->sentDidFinishLoad() &&
709 !frame->loader().provisionalDocumentLoader() && 709 !frame->loader().hasProvisionalNavigation();
710 !isNavigationHandledByClient;
711 } 710 }
712 711
713 void FrameLoader::checkCompleted() { 712 void FrameLoader::checkCompleted() {
714 if (!shouldComplete(m_frame->document())) 713 if (!shouldComplete(m_frame->document()))
715 return; 714 return;
716 715
717 // OK, completed. 716 // OK, completed.
718 m_frame->document()->setReadyState(Document::Complete); 717 m_frame->document()->setReadyState(Document::Complete);
719 if (m_frame->document()->loadEventStillNeeded()) 718 if (m_frame->document()->loadEventStillNeeded())
720 m_frame->document()->implicitClose(); 719 m_frame->document()->implicitClose();
(...skipping 1185 matching lines...) Expand 10 before | Expand all | Expand 10 after
1906 m_documentLoader ? m_documentLoader->url() : String()); 1905 m_documentLoader ? m_documentLoader->url() : String());
1907 return tracedValue; 1906 return tracedValue;
1908 } 1907 }
1909 1908
1910 inline void FrameLoader::takeObjectSnapshot() const { 1909 inline void FrameLoader::takeObjectSnapshot() const {
1911 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, 1910 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this,
1912 toTracedValue()); 1911 toTracedValue());
1913 } 1912 }
1914 1913
1915 } // namespace blink 1914 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/loader/FrameLoader.h ('k') | third_party/WebKit/Source/web/WebLocalFrameImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698