| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
| 6 | 6 |
| 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" | 7 #include "content/browser/loader/resource_dispatcher_host_impl.h" |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 1289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1300 false, // enable_load_timing | 1300 false, // enable_load_timing |
| 1301 blink::WebReferrerPolicyDefault, | 1301 blink::WebReferrerPolicyDefault, |
| 1302 blink::WebPageVisibilityStateVisible, | 1302 blink::WebPageVisibilityStateVisible, |
| 1303 context, | 1303 context, |
| 1304 base::WeakPtr<ResourceMessageFilter>(), // filter | 1304 base::WeakPtr<ResourceMessageFilter>(), // filter |
| 1305 true); // is_async | 1305 true); // is_async |
| 1306 } | 1306 } |
| 1307 | 1307 |
| 1308 void ResourceDispatcherHostImpl::OnRenderViewHostCreated( | 1308 void ResourceDispatcherHostImpl::OnRenderViewHostCreated( |
| 1309 int child_id, | 1309 int child_id, |
| 1310 int route_id) { | 1310 int route_id, |
| 1311 scheduler_->OnClientCreated(child_id, route_id); | 1311 ResourceScheduler::VisualObserver* observer, |
| 1312 bool is_visible) { |
| 1313 scheduler_->OnClientCreated(child_id, route_id, observer, is_visible); |
| 1312 } | 1314 } |
| 1313 | 1315 |
| 1314 void ResourceDispatcherHostImpl::OnRenderViewHostDeleted( | 1316 void ResourceDispatcherHostImpl::OnRenderViewHostDeleted( |
| 1315 int child_id, | 1317 int child_id, |
| 1316 int route_id) { | 1318 int route_id) { |
| 1317 scheduler_->OnClientDeleted(child_id, route_id); | 1319 scheduler_->OnClientDeleted(child_id, route_id); |
| 1318 CancelRequestsForRoute(child_id, route_id); | 1320 CancelRequestsForRoute(child_id, route_id); |
| 1319 } | 1321 } |
| 1320 | 1322 |
| 1321 // This function is only used for saving feature. | 1323 // This function is only used for saving feature. |
| (...skipping 659 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1981 | 1983 |
| 1982 // Add a flag to selectively bypass the data reduction proxy if the resource | 1984 // Add a flag to selectively bypass the data reduction proxy if the resource |
| 1983 // type is not an image. | 1985 // type is not an image. |
| 1984 if (request_data.resource_type != RESOURCE_TYPE_IMAGE) | 1986 if (request_data.resource_type != RESOURCE_TYPE_IMAGE) |
| 1985 load_flags |= net::LOAD_BYPASS_DATA_REDUCTION_PROXY; | 1987 load_flags |= net::LOAD_BYPASS_DATA_REDUCTION_PROXY; |
| 1986 | 1988 |
| 1987 return load_flags; | 1989 return load_flags; |
| 1988 } | 1990 } |
| 1989 | 1991 |
| 1990 } // namespace content | 1992 } // namespace content |
| OLD | NEW |