summaryrefslogtreecommitdiffstats
path: root/content/browser/loader/async_resource_handler.cc
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-31 00:59:40 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-31 00:59:40 +0000
commit6c1e05217fb089245b77e39fd6a46f26c4b85e54 (patch)
tree770ce08ff82343a522b92e37558faa1aff8e4804 /content/browser/loader/async_resource_handler.cc
parent1ecda815adaacdc68dc7769c1f34d5182799abc4 (diff)
downloadchromium_src-6c1e05217fb089245b77e39fd6a46f26c4b85e54.zip
chromium_src-6c1e05217fb089245b77e39fd6a46f26c4b85e54.tar.gz
chromium_src-6c1e05217fb089245b77e39fd6a46f26c4b85e54.tar.bz2
content: ResourceType cleanup.
0) Converted the ResourceType::Type enum to ResourceType enum in content namespace, like this: enum ResourceType { RESOURCE_TYPE_MAIN_FRAME = 0, //... RESOURCE_TYPE_SUB_FRAME, // ... RESOURCE_TYPE_STYLESHEET, // ... . . . }; 1) FromWebURLRequest() is is only called from within content (child & renderer), moved into content/child/web_url_request_util.* and renamed to WebURLRequestToResourceType(). 2) ValidType/FromInt/IsSubresource aren't called from anywhere. Removed. 3) IsSharedWorker/IsServiceWorker are not necessary, they're just an enum comparison and are only called in 5 places. Removed them and just the if check directly. -IsFrame is called in a number of places. Leave it in this header as a function. Since it's not scoped in a class anymore, it needs a more descriptive name. Renamed to IsResourceTypeFrame(). BUG=None TEST=None R=jam@chromium.org TBR=darin@chromium # trivial changes all around src/ Review URL: https://codereview.chromium.org/425653002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286665 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/loader/async_resource_handler.cc')
-rw-r--r--content/browser/loader/async_resource_handler.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/content/browser/loader/async_resource_handler.cc b/content/browser/loader/async_resource_handler.cc
index 69e831bd2..825fc2f4 100644
--- a/content/browser/loader/async_resource_handler.cc
+++ b/content/browser/loader/async_resource_handler.cc
@@ -185,7 +185,7 @@ bool AsyncResourceHandler::OnResponseStarted(ResourceResponse* response,
HostZoomMap* host_zoom_map =
GetHostZoomMapForResourceContext(info->GetContext());
- if (info->GetResourceType() == ResourceType::MAIN_FRAME && host_zoom_map) {
+ if (info->GetResourceType() == RESOURCE_TYPE_MAIN_FRAME && host_zoom_map) {
const GURL& request_url = request()->url();
info->filter()->Send(new ViewMsg_SetZoomLevelForLoadingURL(
info->GetRouteID(),