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

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

Issue 2124253002: FrameLoader: Fix NavigationType for FrameLoadTypeReloadMainResource (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com>
6 * Copyright (C) Research In Motion Limited 2009. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2009. All rights reserved.
7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> 7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com>
8 * Copyright (C) 2011 Google Inc. All rights reserved. 8 * Copyright (C) 2011 Google Inc. All rights reserved.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
(...skipping 842 matching lines...) Expand 10 before | Expand all | Expand 10 after
853 { 853 {
854 if (!targetFrame && !request.frameName().isEmpty()) 854 if (!targetFrame && !request.frameName().isEmpty())
855 return true; 855 return true;
856 // FIXME: This case is a workaround for the fact that ctrl+clicking a form s ubmission incorrectly 856 // FIXME: This case is a workaround for the fact that ctrl+clicking a form s ubmission incorrectly
857 // sends as a GET rather than a POST if it creates a new window in a differe nt process. 857 // sends as a GET rather than a POST if it creates a new window in a differe nt process.
858 return request.form() && policy != NavigationPolicyCurrentTab; 858 return request.form() && policy != NavigationPolicyCurrentTab;
859 } 859 }
860 860
861 static NavigationType determineNavigationType(FrameLoadType frameLoadType, bool isFormSubmission, bool haveEvent) 861 static NavigationType determineNavigationType(FrameLoadType frameLoadType, bool isFormSubmission, bool haveEvent)
862 { 862 {
863 bool isReload = frameLoadType == FrameLoadTypeReload || frameLoadType == Fra meLoadTypeReloadBypassingCache; 863 bool isReload = frameLoadType == FrameLoadTypeReload || frameLoadType == Fra meLoadTypeReloadMainResource || frameLoadType == FrameLoadTypeReloadBypassingCac he;
864 bool isBackForward = isBackForwardLoadType(frameLoadType); 864 bool isBackForward = isBackForwardLoadType(frameLoadType);
865 if (isFormSubmission) 865 if (isFormSubmission)
866 return (isReload || isBackForward) ? NavigationTypeFormResubmitted : Nav igationTypeFormSubmitted; 866 return (isReload || isBackForward) ? NavigationTypeFormResubmitted : Nav igationTypeFormSubmitted;
867 if (haveEvent) 867 if (haveEvent)
868 return NavigationTypeLinkClicked; 868 return NavigationTypeLinkClicked;
869 if (isReload) 869 if (isReload)
870 return NavigationTypeReload; 870 return NavigationTypeReload;
871 if (isBackForward) 871 if (isBackForward)
872 return NavigationTypeBackForward; 872 return NavigationTypeBackForward;
873 return NavigationTypeOther; 873 return NavigationTypeOther;
(...skipping 740 matching lines...) Expand 10 before | Expand all | Expand 10 after
1614 tracedValue->setString("documentLoaderURL", m_documentLoader ? m_documentLoa der->url() : String()); 1614 tracedValue->setString("documentLoaderURL", m_documentLoader ? m_documentLoa der->url() : String());
1615 return tracedValue; 1615 return tracedValue;
1616 } 1616 }
1617 1617
1618 inline void FrameLoader::takeObjectSnapshot() const 1618 inline void FrameLoader::takeObjectSnapshot() const
1619 { 1619 {
1620 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, toTraced Value()); 1620 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, toTraced Value());
1621 } 1621 }
1622 1622
1623 } // namespace blink 1623 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698