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

Unified Diff: content/browser/loader/resource_request_info_impl.cc

Issue 2484633004: Change Lo-Fi bool to bitmask to support multiple Previews types (Closed)
Patch Set: fix ContentResourceProviderTest 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/loader/resource_request_info_impl.cc
diff --git a/content/browser/loader/resource_request_info_impl.cc b/content/browser/loader/resource_request_info_impl.cc
index 48720836c0a9e57a8b2f8ee742aa3d9aedbd4153..08487daf7e7a4566d2837e1d6edc4ad52c9ba40e 100644
--- a/content/browser/loader/resource_request_info_impl.cc
+++ b/content/browser/loader/resource_request_info_impl.cc
@@ -52,7 +52,7 @@ void ResourceRequestInfo::AllocateForTesting(net::URLRequest* request,
bool parent_is_main_frame,
bool allow_download,
bool is_async,
- bool is_using_lofi) {
+ PreviewsState previews_state) {
// Make sure both |is_main_frame| and |parent_is_main_frame| aren't set at the
// same time.
DCHECK(!(is_main_frame && parent_is_main_frame));
@@ -86,7 +86,7 @@ void ResourceRequestInfo::AllocateForTesting(net::URLRequest* request,
context, // context
false, // report_raw_headers
is_async, // is_async
- is_using_lofi, // is_using_lofi
+ previews_state, // previews_state
std::string(), // original_headers
nullptr, // body
false); // initiated_in_secure_context
@@ -153,7 +153,7 @@ ResourceRequestInfoImpl::ResourceRequestInfoImpl(
ResourceContext* context,
bool report_raw_headers,
bool is_async,
- bool is_using_lofi,
+ PreviewsState previews_state,
const std::string& original_headers,
const scoped_refptr<ResourceRequestBodyImpl> body,
bool initiated_in_secure_context)
@@ -184,7 +184,7 @@ ResourceRequestInfoImpl::ResourceRequestInfoImpl(
context_(context),
report_raw_headers_(report_raw_headers),
is_async_(is_async),
- is_using_lofi_(is_using_lofi),
+ previews_state_(previews_state),
original_headers_(original_headers),
body_(body),
initiated_in_secure_context_(initiated_in_secure_context) {}
@@ -297,8 +297,8 @@ bool ResourceRequestInfoImpl::IsDownload() const {
return is_download_;
}
-bool ResourceRequestInfoImpl::IsUsingLoFi() const {
- return is_using_lofi_;
+PreviewsState ResourceRequestInfoImpl::GetPreviewsState() const {
+ return previews_state_;
}
bool ResourceRequestInfoImpl::ShouldReportRawHeaders() const {
« no previous file with comments | « content/browser/loader/resource_request_info_impl.h ('k') | content/browser/service_worker/link_header_support_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698