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

Issue 370833002: Move resource_type.* from webkit/ to content/. (Closed)

Created:
6 years, 5 months ago by tfarina
Modified:
6 years, 4 months ago
Reviewers:
jam
CC:
chromium-reviews, skanuj+watch_chromium.org, nkostylev+watch_chromium.org, tzik, tburkard+watch_chromium.org, dhollowa+watch_chromium.org, dougw+watch_chromium.org, nasko+codewatch_chromium.org, serviceworker-reviews, stevenjb+watch_chromium.org, miu+watch_chromium.org, extensions-reviews_chromium.org, cbentzel+watch_chromium.org, melevin+watch_chromium.org, jam, kinuko+serviceworker, dominich, darin-cc_chromium.org, alecflett+watch_chromium.org, chromium-apps-reviews_chromium.org, michaeln, creis+watch_chromium.org, jsbell+serviceworker_chromium.org, nhiroki, gavinp+prer_chromium.org, jfweitz+watch_chromium.org, oshima+watch_chromium.org, horo+watch_chromium.org, Jered, davidben+watch_chromium.org, donnd+watch_chromium.org, dominich+watch_chromium.org, David Black, samarth+watch_chromium.org, kmadhusu+watch_chromium.org, davemoore+watch_chromium.org
Project:
chromium
Visibility:
Public.

Description

Move resource_type.* from webkit/ to content/. Put it in content namespace while doing this. BUG=338338 TEST=None TBR=jam@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=281469

Patch Set 1 #

Patch Set 2 : android_webview fix #

Patch Set 3 : win8 fix #

Patch Set 4 : chromeos fix #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+143 lines, -220 lines) Patch
M android_webview/browser/aw_content_browser_client.h View 1 1 chunk +1 line, -1 line 0 comments Download
M android_webview/browser/aw_content_browser_client.cc View 1 1 chunk +1 line, -0 lines 0 comments Download
M android_webview/browser/renderer_host/aw_resource_dispatcher_host_delegate.h View 1 1 chunk +1 line, -1 line 0 comments Download
M android_webview/browser/renderer_host/aw_resource_dispatcher_host_delegate.cc View 1 1 chunk +1 line, -0 lines 0 comments Download
M android_webview/native/aw_contents_io_thread_client_impl.cc View 1 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/captive_portal/captive_portal_tab_helper.h View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/captive_portal/captive_portal_tab_helper.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/captive_portal/captive_portal_tab_helper_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/chrome_content_browser_client.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/chrome_content_browser_client.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/chromeos/login/signin/merge_session_throttle.h View 1 2 3 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/chromeos/login/signin/merge_session_throttle.cc View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_attribute.h View 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_attribute.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_attribute_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/web_navigation/web_navigation_api.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/extensions/api/web_navigation/web_navigation_apitest.cc View 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/extensions/api/web_request/web_request_api.h View 4 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/extensions/api/web_request/web_request_api.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/web_request/web_request_api_helpers.h View 2 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/extensions/api/web_request/web_request_api_helpers.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/api/web_request/web_request_permissions_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/url_request_util.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/user_script_listener.h View 3 chunks +4 lines, -3 lines 0 comments Download
M chrome/browser/extensions/user_script_listener.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/extensions/user_script_listener_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/guest_view/web_view/web_view_guest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/net/chrome_network_delegate.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/prerender/prerender_contents.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/prerender/prerender_pending_swap_throttle.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/prerender/prerender_resource_throttle.h View 3 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/prerender/prerender_resource_throttle.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/prerender/prerender_tracker_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/prerender/prerender_util.h View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/prerender/prerender_util.cc View 1 chunk +3 lines, -1 line 0 comments Download
M chrome/browser/prerender/prerender_util_unittest.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.h View 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate_browsertest.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/browser_feature_extractor.h View 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/safe_browsing/browser_feature_extractor.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/safe_browsing/client_side_detection_host.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/safe_browsing/client_side_detection_host.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/safe_browsing/client_side_detection_host_unittest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/search/iframe_source_unittest.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/renderer/chrome_render_process_observer.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/renderer/security_filter_peer.h View 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/renderer/security_filter_peer.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M components/navigation_interception/intercept_navigation_resource_throttle_unittest.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/appcache/appcache_host.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/appcache/appcache_interceptor.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/appcache/appcache_request_handler.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/child_process_security_policy_impl.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_dispatcher_host_impl.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_message_filter.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_request_info_impl.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/loader/resource_scheduler_unittest.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/plugin_process_host.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 2 chunks +1 line, -1 line 0 comments Download
M content/browser/service_worker/service_worker_provider_host.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/service_worker/service_worker_request_handler.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/service_worker/service_worker_utils.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/service_worker/service_worker_write_to_cache_job.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/ssl/ssl_error_handler.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/ssl/ssl_policy.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/ssl/ssl_policy.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/ssl/ssl_request_info.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/web_contents/web_contents_impl.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/worker_host/worker_process_host.h View 1 chunk +1 line, -1 line 0 comments Download
M content/browser/worker_host/worker_process_host.cc View 2 chunks +1 line, -1 line 0 comments Download
M content/child/request_info.h View 1 chunk +1 line, -1 line 0 comments Download
M content/child/resource_dispatcher.h View 1 chunk +1 line, -1 line 0 comments Download
M content/child/resource_dispatcher.cc View 1 chunk +1 line, -1 line 0 comments Download
M content/child/site_isolation_policy.h View 1 chunk +1 line, -1 line 0 comments Download
M content/common/content_param_traits_macros.h View 1 chunk +3 lines, -2 lines 0 comments Download
M content/common/resource_messages.h View 1 chunk +1 line, -1 line 0 comments Download
M content/common/view_messages.h View 1 chunk +1 line, -1 line 0 comments Download
M content/content_common.gypi View 1 chunk +2 lines, -0 lines 0 comments Download
M content/public/browser/content_browser_client.h View 2 chunks +1 line, -1 line 0 comments Download
M content/public/browser/load_from_memory_cache_details.h View 1 chunk +1 line, -1 line 0 comments Download
M content/public/browser/resource_dispatcher_host_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M content/public/browser/resource_request_details.h View 1 chunk +1 line, -1 line 0 comments Download
M content/public/browser/resource_request_info.h View 1 chunk +1 line, -1 line 0 comments Download
M content/public/child/resource_dispatcher_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
A + content/public/common/resource_type.h View 4 chunks +14 lines, -12 lines 2 comments Download
A + content/public/common/resource_type.cc View 2 chunks +5 lines, -1 line 0 comments Download
M extensions/browser/extension_protocols.cc View 1 chunk +1 line, -0 lines 0 comments Download
M extensions/browser/extension_protocols_unittest.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M webkit/common/BUILD.gn View 1 chunk +0 lines, -2 lines 0 comments Download
D webkit/common/resource_type.h View 1 chunk +0 lines, -76 lines 0 comments Download
D webkit/common/resource_type.cc View 1 chunk +0 lines, -51 lines 0 comments Download
M webkit/common/webkit_common.gyp View 1 chunk +0 lines, -2 lines 0 comments Download

Messages

Total messages: 13 (0 generated)
tfarina
TBRing...
6 years, 5 months ago (2014-07-04 23:34:29 UTC) #1
tfarina
The CQ bit was checked by tfarina@chromium.org
6 years, 5 months ago (2014-07-04 23:34:31 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tfarina@chromium.org/370833002/1
6 years, 5 months ago (2014-07-04 23:35:20 UTC) #3
tfarina
The CQ bit was checked by tfarina@chromium.org
6 years, 5 months ago (2014-07-04 23:49:46 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tfarina@chromium.org/370833002/40001
6 years, 5 months ago (2014-07-04 23:50:12 UTC) #5
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_chromium_chromeos_clang_dbg on tryserver.chromium ...
6 years, 5 months ago (2014-07-05 03:13:18 UTC) #6
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 5 months ago (2014-07-05 03:25:30 UTC) #7
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel on tryserver.chromium (http://build.chromium.org/p/tryserver.chromium/builders/linux_chromium_chromeos_rel/builds/44660)
6 years, 5 months ago (2014-07-05 03:25:32 UTC) #8
tfarina
The CQ bit was checked by tfarina@chromium.org
6 years, 5 months ago (2014-07-05 15:25:46 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tfarina@chromium.org/370833002/60001
6 years, 5 months ago (2014-07-05 15:26:35 UTC) #10
commit-bot: I haz the power
Change committed as 281469
6 years, 5 months ago (2014-07-05 19:10:14 UTC) #11
jam
thanks for doing this, some comments as the content api is stricter than src/webkit https://codereview.chromium.org/370833002/diff/60001/content/public/common/resource_type.h ...
6 years, 5 months ago (2014-07-14 15:16:31 UTC) #12
tfarina
6 years, 4 months ago (2014-07-27 23:50:02 UTC) #13
Message was sent while issue was closed.
https://codereview.chromium.org/370833002/diff/60001/content/public/common/re...
File content/public/common/resource_type.h (right):

https://codereview.chromium.org/370833002/diff/60001/content/public/common/re...
content/public/common/resource_type.h:19: MAIN_FRAME = 0,  // top level page
On 2014/07/14 15:16:31, jam wrote:
> now that this is in content/public, it should conform to the Content API's
> guidelines for enums (see
> http://www.chromium.org/developers/content-module/content-api).
> 
> i.e. this should be 
> 
> enum ResourceType {
>   RESOURCE_TYPE_MAIN_FRAME = 0,  //...
>   RESOURCE_TYPE_SUB_FRAME,  // ...
>   RESOURCE_TYPE_STYLESHEET,  // ...
> .
> .
> .
> };
> 
> For the methods below, they should be moved out:
> -FromTargetType is only called from within content (child & renderer), so it
> should be moved to content/child/target_type_conversion.h/cc (or similar, just
a
> proposed file name)
> -ValidType/FromInt/IsSubresource aren't called from anywhere so they can be
> removed
> -IsSharedWorker/IsServiceWorker are not necessary, they're just an enum
> comparison and are only called in 5 places. so remove them and just have the
> source code do the if check
> -IsFrame is called in a number of places, so probably best to leave it in this
> header as a function. since it's not scoped in a class anymore, it would need
a
> more descriptive name. something like
> bool IsResourceTypeFrame(ResourceType resource_type);
Hi John,

I will be addressing this here -> https://codereview.chromium.org/425653002

Thanks for the analysis.

I didn't expect so many usages of ResourceType:: :-/

So it will take a while until I can get it all, but I will get there.

Powered by Google App Engine
This is Rietveld 408576698