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

Unified Diff: trunk/src/mojo/shell/ui_service_loader_android.cc

Issue 447063005: Revert 288013 "First cut at "content handling" support in Mojo." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 4 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 | « trunk/src/mojo/shell/ui_service_loader_android.h ('k') | trunk/src/mojo/shell/view_manager_loader.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/mojo/shell/ui_service_loader_android.cc
===================================================================
--- trunk/src/mojo/shell/ui_service_loader_android.cc (revision 288042)
+++ trunk/src/mojo/shell/ui_service_loader_android.cc (working copy)
@@ -15,12 +15,10 @@
explicit UILoader(ServiceLoader* loader) : loader_(loader) {}
~UILoader() {}
- void Load(ServiceManager* manager,
- const GURL& url,
- ScopedMessagePipeHandle shell_handle) {
- scoped_refptr<LoadCallbacks> callbacks(
- new ServiceLoader::SimpleLoadCallbacks(shell_handle.Pass()));
- loader_->Load(manager, url, callbacks);
+ void LoadService(ServiceManager* manager,
+ const GURL& url,
+ ScopedMessagePipeHandle shell_handle) {
+ loader_->LoadService(manager, url, shell_handle.Pass());
}
void OnServiceError(ServiceManager* manager, const GURL& url) {
@@ -44,20 +42,17 @@
base::Bind(&UIServiceLoader::ShutdownOnUIThread, base::Unretained(this)));
}
-void UIServiceLoader::Load(ServiceManager* manager,
- const GURL& url,
- scoped_refptr<LoadCallbacks> callbacks) {
- ScopedMessagePipeHandle shell_handle = callbacks->RegisterApplication();
- if (!shell_handle.is_valid())
- return;
+void UIServiceLoader::LoadService(ServiceManager* manager,
+ const GURL& url,
+ ScopedMessagePipeHandle shell_handle) {
context_->ui_loop()->PostTask(
FROM_HERE,
- base::Bind(&UIServiceLoader::LoadOnUIThread,
- base::Unretained(this),
- manager,
- url,
- base::Owned(
- new ScopedMessagePipeHandle(shell_handle.Pass()))));
+ base::Bind(
+ &UIServiceLoader::LoadServiceOnUIThread,
+ base::Unretained(this),
+ manager,
+ url,
+ base::Owned(new ScopedMessagePipeHandle(shell_handle.Pass()))));
}
void UIServiceLoader::OnServiceError(ServiceManager* manager, const GURL& url) {
@@ -69,12 +64,13 @@
url));
}
-void UIServiceLoader::LoadOnUIThread(ServiceManager* manager,
- const GURL& url,
- ScopedMessagePipeHandle* shell_handle) {
+void UIServiceLoader::LoadServiceOnUIThread(
+ ServiceManager* manager,
+ const GURL& url,
+ ScopedMessagePipeHandle* shell_handle) {
if (!ui_loader_)
ui_loader_ = new UILoader(loader_.get());
- ui_loader_->Load(manager, url, shell_handle->Pass());
+ ui_loader_->LoadService(manager, url, shell_handle->Pass());
}
void UIServiceLoader::OnServiceErrorOnUIThread(ServiceManager* manager,
« no previous file with comments | « trunk/src/mojo/shell/ui_service_loader_android.h ('k') | trunk/src/mojo/shell/view_manager_loader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698