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

Unified Diff: mojo/shell/application_manager.cc

Issue 1161463004: Move URL Loader creation to a separate factory object. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/shell/application_manager.h ('k') | mojo/shell/network_fetcher.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/application_manager.cc
diff --git a/mojo/shell/application_manager.cc b/mojo/shell/application_manager.cc
index 3354fbd77487e777098982d42f9fb3d33dd65890..39b133fa76e610fd3b260c906f6a65714bfe387c 100644
--- a/mojo/shell/application_manager.cc
+++ b/mojo/shell/application_manager.cc
@@ -179,8 +179,8 @@ void ApplicationManager::ConnectToApplicationInternal(
return;
}
- if (!network_service_)
- ConnectToService(GURL("mojo:network_service"), &network_service_);
+ if (!url_loader_factory_)
+ ConnectToService(GURL("mojo:network_service"), &url_loader_factory_);
const NativeApplicationCleanup cleanup =
base::CommandLine::ForCurrentProcess()->HasSwitch(
@@ -193,12 +193,13 @@ void ApplicationManager::ConnectToApplicationInternal(
mojo::URLRequestPtr resolved_url_request(mojo::URLRequest::New());
resolved_url_request->url = resolved_url.spec();
new NetworkFetcher(disable_cache_, resolved_url_request.Pass(),
- network_service_.get(), base::Bind(callback, cleanup));
+ url_loader_factory_.get(),
+ base::Bind(callback, cleanup));
return;
}
new NetworkFetcher(disable_cache_, requested_url.Pass(),
- network_service_.get(), base::Bind(callback, cleanup));
+ url_loader_factory_.get(), base::Bind(callback, cleanup));
}
bool ApplicationManager::ConnectToRunningApplication(
« no previous file with comments | « mojo/shell/application_manager.h ('k') | mojo/shell/network_fetcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698