Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/data_reduction_proxy/content/browser/content_lofi_decider.h " | 5 #include "components/data_reduction_proxy/content/browser/content_lofi_decider.h " |
| 6 | 6 |
| 7 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_param s.h" | 7 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_param s.h" |
| 8 #include "content/public/browser/resource_request_info.h" | 8 #include "content/public/browser/resource_request_info.h" |
| 9 #include "net/url_request/url_request.h" | 9 #include "net/url_request/url_request.h" |
| 10 | 10 |
| 11 namespace data_reduction_proxy { | 11 namespace data_reduction_proxy { |
| 12 | 12 |
| 13 ContentLoFiDecider::ContentLoFiDecider() {} | 13 ContentLoFiDecider::ContentLoFiDecider() {} |
| 14 | 14 |
| 15 ContentLoFiDecider::~ContentLoFiDecider() {} | 15 ContentLoFiDecider::~ContentLoFiDecider() {} |
| 16 | 16 |
| 17 bool ContentLoFiDecider::IsUsingLoFiMode(const net::URLRequest& request) const { | 17 bool ContentLoFiDecider::IsUsingLoFiMode(const net::URLRequest& request) const { |
| 18 // TODO: will be check of ResourceRequestInfo::IsUsingLoFi | 18 const content::ResourceRequestInfo* request_info = |
| 19 content::ResourceRequestInfo::ForRequest(&request); | |
| 20 if (request_info) { | |
| 21 return request_info->IsUsingLoFi(); | |
| 22 } | |
|
mmenke
2015/10/13 15:42:49
nit: Remove braces
megjablon
2015/10/14 18:09:46
Done.
| |
| 19 return false; | 23 return false; |
| 20 } | 24 } |
| 21 | 25 |
| 22 } // namespace data_reduction_roxy | 26 } // namespace data_reduction_roxy |
| OLD | NEW |