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

Unified Diff: content/common/navigation_params.h

Issue 1310743003: Consistently use LoFi for an entire page (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bengr comments and rebase 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
« no previous file with comments | « content/common/frame_messages.h ('k') | content/common/navigation_params.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/navigation_params.h
diff --git a/content/common/navigation_params.h b/content/common/navigation_params.h
index 3ed83774684c3564207ada5eeda8081c506e3b9b..8093623e59a53b8423a23f21a2d91f88905a399b 100644
--- a/content/common/navigation_params.h
+++ b/content/common/navigation_params.h
@@ -23,6 +23,18 @@ class RefCountedMemory;
namespace content {
+// The LoFi state which determines whether to add the Lo-Fi header.
+enum LoFiState {
+ // Let the browser process decide whether or not to request the Lo-Fi version.
+ LOFI_UNSPECIFIED = 0,
+
+ // Request a normal (non-Lo-Fi) version of the resource.
+ LOFI_OFF,
+
+ // Request a Lo-Fi version of the resource.
+ LOFI_ON,
+};
+
// PlzNavigate
// Helper function to determine if the navigation to |url| should make a request
// to the network stack. A request should not be sent for data URLs, JavaScript
@@ -47,7 +59,8 @@ struct CONTENT_EXPORT CommonNavigationParams {
base::TimeTicks ui_timestamp,
FrameMsg_UILoadMetricsReportType::Value report_type,
const GURL& base_url_for_data_url,
- const GURL& history_url_for_data_url);
+ const GURL& history_url_for_data_url,
+ LoFiState lofi_state);
~CommonNavigationParams();
// The URL to navigate to.
@@ -90,6 +103,10 @@ struct CONTENT_EXPORT CommonNavigationParams {
// History URL for use in Blink's SubstituteData.
// Is only used with data: URLs.
GURL history_url_for_data_url;
+
+ // Whether or not to request a LoFi version of the document or let the browser
+ // decide.
+ LoFiState lofi_state;
};
// Provided by the renderer ----------------------------------------------------
« no previous file with comments | « content/common/frame_messages.h ('k') | content/common/navigation_params.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698