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

Unified Diff: content/browser/frame_host/navigator_impl.cc

Issue 1310743003: Consistently use LoFi for an entire page (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: test fix Created 5 years, 2 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: content/browser/frame_host/navigator_impl.cc
diff --git a/content/browser/frame_host/navigator_impl.cc b/content/browser/frame_host/navigator_impl.cc
index 2e9a114eef9012d0c70904e3f3211b523ec31658..bc9a50f07217254b22f86704d52ff70d80c16d8e 100644
--- a/content/browser/frame_host/navigator_impl.cc
+++ b/content/browser/frame_host/navigator_impl.cc
@@ -51,6 +51,7 @@ FrameMsg_Navigate_Type::Value GetNavigationType(
NavigationController::ReloadType reload_type) {
switch (reload_type) {
case NavigationControllerImpl::RELOAD:
+ case NavigationControllerImpl::RELOAD_DISABLE_LOFI_MODE:
return FrameMsg_Navigate_Type::RELOAD;
case NavigationControllerImpl::RELOAD_IGNORING_CACHE:
return FrameMsg_Navigate_Type::RELOAD_IGNORING_CACHE;
@@ -334,9 +335,14 @@ bool NavigatorImpl::NavigateToEntry(
// Create the navigation parameters.
FrameMsg_Navigate_Type::Value navigation_type =
GetNavigationType(controller_->GetBrowserContext(), entry, reload_type);
+ LoFiState lofi_state =
+ (reload_type ==
+ NavigationController::ReloadType::RELOAD_DISABLE_LOFI_MODE
+ ? LOFI_OFF
+ : LOFI_UNSPECIFIED);
dest_render_frame_host->Navigate(
- entry.ConstructCommonNavigationParams(dest_url, dest_referrer,
- frame_entry, navigation_type),
+ entry.ConstructCommonNavigationParams(
+ dest_url, dest_referrer, frame_entry, navigation_type, lofi_state),
entry.ConstructStartNavigationParams(),
entry.ConstructRequestNavigationParams(
frame_entry, navigation_start, is_same_document_history_load,

Powered by Google App Engine
This is Rietveld 408576698