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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc

Issue 2278823003: Change net::LOAD_MAIN_FRAME to net::LOAD_MAIN_FRAME_DEPRECATED to discourage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added deprecation flag to two recent tests. Created 4 years, 4 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: components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
index 8ecf20e4141a15c840026df345c472c76ff607d5..a6fa327ebc7a8fa126a65d6f6b510fd9283df16d 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
@@ -224,7 +224,7 @@ void DataReductionProxyNetworkDelegate::OnBeforeURLRequestInternal(
// |data_reduction_proxy_io_data_| can be NULL for Webview.
if (data_reduction_proxy_io_data_ &&
- (request->load_flags() & net::LOAD_MAIN_FRAME)) {
+ (request->load_flags() & net::LOAD_MAIN_FRAME_DEPRECATED)) {
data_reduction_proxy_io_data_->SetLoFiModeActiveOnMainFrame(false);
}
}
@@ -266,7 +266,7 @@ void DataReductionProxyNetworkDelegate::OnBeforeSendHeadersInternal(
data->set_session_key(
data_reduction_proxy_request_options_->GetSecureSession());
data->set_original_request_url(request->original_url());
- if ((request->load_flags() & net::LOAD_MAIN_FRAME) &&
+ if ((request->load_flags() & net::LOAD_MAIN_FRAME_DEPRECATED) &&
request->context()->network_quality_estimator()) {
data->set_effective_connection_type(request->context()
->network_quality_estimator()
@@ -280,7 +280,7 @@ void DataReductionProxyNetworkDelegate::OnBeforeSendHeadersInternal(
const bool is_using_lofi_mode =
lofi_decider->MaybeAddLoFiDirectiveToHeaders(*request, headers);
- if ((request->load_flags() & net::LOAD_MAIN_FRAME)) {
+ if ((request->load_flags() & net::LOAD_MAIN_FRAME_DEPRECATED)) {
data_reduction_proxy_io_data_->SetLoFiModeActiveOnMainFrame(
is_using_lofi_mode);
}

Powered by Google App Engine
This is Rietveld 408576698