| 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 #include "content/browser/loader/async_resource_handler.h" | 5 #include "content/browser/loader/async_resource_handler.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 if (!info->filter()) | 186 if (!info->filter()) |
| 187 return false; | 187 return false; |
| 188 | 188 |
| 189 if (rdh_->delegate()) { | 189 if (rdh_->delegate()) { |
| 190 rdh_->delegate()->OnResponseStarted( | 190 rdh_->delegate()->OnResponseStarted( |
| 191 request(), info->GetContext(), response, info->filter()); | 191 request(), info->GetContext(), response, info->filter()); |
| 192 } | 192 } |
| 193 | 193 |
| 194 DevToolsNetLogObserver::PopulateResponseInfo(request(), response); | 194 DevToolsNetLogObserver::PopulateResponseInfo(request(), response); |
| 195 | 195 |
| 196 HostZoomMap* host_zoom_map = | 196 const HostZoomMap* host_zoom_map = info->filter()->GetHostZoomMap(); |
| 197 GetHostZoomMapForResourceContext(info->GetContext()); | |
| 198 | 197 |
| 199 if (info->GetResourceType() == RESOURCE_TYPE_MAIN_FRAME && host_zoom_map) { | 198 if (info->GetResourceType() == RESOURCE_TYPE_MAIN_FRAME && host_zoom_map) { |
| 200 const GURL& request_url = request()->url(); | 199 const GURL& request_url = request()->url(); |
| 201 info->filter()->Send(new ViewMsg_SetZoomLevelForLoadingURL( | 200 info->filter()->Send(new ViewMsg_SetZoomLevelForLoadingURL( |
| 202 info->GetRouteID(), | 201 info->GetRouteID(), |
| 203 request_url, host_zoom_map->GetZoomLevelForHostAndScheme( | 202 request_url, host_zoom_map->GetZoomLevelForHostAndScheme( |
| 204 request_url.scheme(), | 203 request_url.scheme(), |
| 205 net::GetHostOrSpecFromURL(request_url)))); | 204 net::GetHostOrSpecFromURL(request_url)))); |
| 206 } | 205 } |
| 207 | 206 |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 401 request()->LogUnblocked(); | 400 request()->LogUnblocked(); |
| 402 controller()->Resume(); | 401 controller()->Resume(); |
| 403 } | 402 } |
| 404 } | 403 } |
| 405 | 404 |
| 406 void AsyncResourceHandler::OnDefer() { | 405 void AsyncResourceHandler::OnDefer() { |
| 407 request()->LogBlockedBy("AsyncResourceHandler"); | 406 request()->LogBlockedBy("AsyncResourceHandler"); |
| 408 } | 407 } |
| 409 | 408 |
| 410 } // namespace content | 409 } // namespace content |
| OLD | NEW |