Chromium Code Reviews| Index: content/browser/loader/navigation_url_loader_network_service.cc |
| diff --git a/content/browser/loader/navigation_url_loader_network_service.cc b/content/browser/loader/navigation_url_loader_network_service.cc |
| index f7d814d7f136aa336bfd55720a1cb4967237c4fe..dac8ea52b916e62fe20c87743de358a390041832 100644 |
| --- a/content/browser/loader/navigation_url_loader_network_service.cc |
| +++ b/content/browser/loader/navigation_url_loader_network_service.cc |
| @@ -9,8 +9,6 @@ |
| #include "base/memory/ptr_util.h" |
| #include "base/trace_event/trace_event.h" |
| #include "content/browser/appcache/appcache_navigation_handle.h" |
| -#include "content/browser/appcache/appcache_navigation_handle_core.h" |
| -#include "content/browser/appcache/appcache_request_handler.h" |
| #include "content/browser/blob_storage/chrome_blob_storage_context.h" |
| #include "content/browser/frame_host/frame_tree_node.h" |
| #include "content/browser/frame_host/navigation_request_info.h" |
| @@ -93,20 +91,6 @@ void PrepareNavigationStartOnIO( |
| request_info->common_params.post_data, web_contents_getter); |
| } |
| - // TODO(scottmg): We need to rework AppCache to have it return a |
| - // URLLoaderFactoryPtr[Info] here. We should also try to have it return |
| - // synchronously in as many cases as possible (especially when there's no |
| - // AppCache) to simplify and speed the common case. |
| - if (false /*appcache_handle_core*/) { |
| - AppCacheRequestHandler::InitializeForNavigationNetworkService( |
| - std::move(resource_request), resource_context, appcache_handle_core, |
| - resource_type, |
| - base::Callback<void( |
| - mojom::URLLoaderFactoryPtrInfo, |
| - std::unique_ptr<ResourceRequest>)>() /* TODO(ananta) */); |
| - return; |
| - } |
| - |
| // If we haven't gotten one from the above, then use the one the UI thread |
| // gave us, or otherwise fallback to the default. |
| mojom::URLLoaderFactory* factory; |
| @@ -117,7 +101,11 @@ void PrepareNavigationStartOnIO( |
| url_loader_factory_ptr.Bind(std::move(factory_from_ui)); |
| factory = url_loader_factory_ptr.get(); |
| } else { |
| - factory = url_loader_factory_getter->GetNetworkFactory()->get(); |
| + if (appcache_handle_core) { |
|
jam
2017/05/17 16:51:12
doesn't have to be here, but we should really only
ananta
2017/05/17 18:14:09
That is going to be touch tricky to do at the mome
ananta
2017/05/17 20:45:27
Scratch that. I added code in the AppCacheURLLoade
|
| + factory = url_loader_factory_getter->GetAppCacheFactory()->get(); |
|
kinuko
2017/05/17 16:54:30
So we almost always take this path after this patc
ananta
2017/05/17 18:14:09
Yes.
|
| + } else { |
| + factory = url_loader_factory_getter->GetNetworkFactory()->get(); |
| + } |
| } |
| } |