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

Unified Diff: third_party/WebKit/Source/core/frame/Location.cpp

Issue 2865013002: Add an experimental flag to change location.reload to take a hard-reload (Closed)
Patch Set: Created 3 years, 7 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
Index: third_party/WebKit/Source/core/frame/Location.cpp
diff --git a/third_party/WebKit/Source/core/frame/Location.cpp b/third_party/WebKit/Source/core/frame/Location.cpp
index f80bcff688a06ad829067edbf8185ea51a4f61d3..d231cb0ac10e252dd225637b29a5f7c15ae3537f 100644
--- a/third_party/WebKit/Source/core/frame/Location.cpp
+++ b/third_party/WebKit/Source/core/frame/Location.cpp
@@ -38,6 +38,7 @@
#include "core/frame/LocalDOMWindow.h"
#include "core/frame/LocalFrame.h"
#include "core/loader/FrameLoader.h"
+#include "platform/RuntimeEnabledFeatures.h"
#include "platform/weborigin/KURL.h"
#include "platform/weborigin/SecurityOrigin.h"
@@ -226,8 +227,11 @@ void Location::reload(LocalDOMWindow* current_window) {
return;
if (GetDocument()->Url().ProtocolIsJavaScript())
return;
- dom_window_->GetFrame()->Reload(kFrameLoadTypeReload,
- ClientRedirectPolicy::kClientRedirect);
+ dom_window_->GetFrame()->Reload(
+ RuntimeEnabledFeatures::locationHardReloadEnabled()
+ ? kFrameLoadTypeReloadBypassingCache
+ : kFrameLoadTypeReload,
+ ClientRedirectPolicy::kClientRedirect);
}
void Location::SetLocation(const String& url,
« no previous file with comments | « third_party/WebKit/Source/core/frame/LocalFrame.cpp ('k') | third_party/WebKit/Source/core/loader/NavigationScheduler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698