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

Side by Side Diff: shell/application_manager/application_manager.h

Issue 873453004: Use ShellPtr type in ApplicationLoader instead of untyped handles (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: fix android Created 5 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_ 5 #ifndef SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_
6 #define SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_ 6 #define SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 10
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 ScopedMessagePipeHandle service_handle = 64 ScopedMessagePipeHandle service_handle =
65 ConnectToServiceByName(application_url, Interface::Name_); 65 ConnectToServiceByName(application_url, Interface::Name_);
66 ptr->Bind(service_handle.Pass()); 66 ptr->Bind(service_handle.Pass());
67 } 67 }
68 68
69 ScopedMessagePipeHandle ConnectToServiceByName( 69 ScopedMessagePipeHandle ConnectToServiceByName(
70 const GURL& application_url, 70 const GURL& application_url,
71 const std::string& interface_name); 71 const std::string& interface_name);
72 72
73 void RegisterExternalApplication(const GURL& application_url, 73 void RegisterExternalApplication(const GURL& application_url,
74 ScopedMessagePipeHandle shell); 74 ScopedMessagePipeHandle shell_handle);
75 75
76 // Sets the default Loader to be used if not overridden by SetLoaderForURL() 76 // Sets the default Loader to be used if not overridden by SetLoaderForURL()
77 // or SetLoaderForScheme(). 77 // or SetLoaderForScheme().
78 void set_default_loader(scoped_ptr<ApplicationLoader> loader) { 78 void set_default_loader(scoped_ptr<ApplicationLoader> loader) {
79 default_loader_ = loader.Pass(); 79 default_loader_ = loader.Pass();
80 } 80 }
81 // Sets a Loader to be used for a specific url. 81 // Sets a Loader to be used for a specific url.
82 void SetLoaderForURL(scoped_ptr<ApplicationLoader> loader, const GURL& url); 82 void SetLoaderForURL(scoped_ptr<ApplicationLoader> loader, const GURL& url);
83 // Sets a Loader to be used for a specific url scheme. 83 // Sets a Loader to be used for a specific url scheme.
84 void SetLoaderForScheme(scoped_ptr<ApplicationLoader> loader, 84 void SetLoaderForScheme(scoped_ptr<ApplicationLoader> loader,
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 URLToArgsMap url_to_args_; 148 URLToArgsMap url_to_args_;
149 149
150 base::WeakPtrFactory<ApplicationManager> weak_ptr_factory_; 150 base::WeakPtrFactory<ApplicationManager> weak_ptr_factory_;
151 151
152 DISALLOW_COPY_AND_ASSIGN(ApplicationManager); 152 DISALLOW_COPY_AND_ASSIGN(ApplicationManager);
153 }; 153 };
154 154
155 } // namespace mojo 155 } // namespace mojo
156 156
157 #endif // SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_ 157 #endif // SHELL_APPLICATION_MANAGER_APPLICATION_MANAGER_H_
OLDNEW
« no previous file with comments | « shell/application_manager/application_loader.h ('k') | shell/application_manager/application_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698