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

Unified Diff: content/public/common/service_manager_connection.h

Issue 2456493003: Add frame-specific InterfaceProviderSpec. (Closed)
Patch Set: . Created 4 years, 2 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 | « content/public/app/mojo/content_renderer_manifest.json ('k') | content/public/test/mock_render_thread.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/common/service_manager_connection.h
diff --git a/content/public/common/service_manager_connection.h b/content/public/common/service_manager_connection.h
index 23b8f1a6c3f4b241cd734c7ba236e75b03de0d33..4386b768598c9ff62b71198d948a2c898464ef58 100644
--- a/content/public/common/service_manager_connection.h
+++ b/content/public/common/service_manager_connection.h
@@ -39,6 +39,9 @@ class CONTENT_EXPORT ServiceManagerConnection {
public:
using ServiceRequestHandler =
base::Callback<void(service_manager::mojom::ServiceRequest)>;
+ using OnConnectHandler =
+ base::Callback<void(const service_manager::ServiceInfo&,
+ const service_manager::ServiceInfo&)>;
using Factory =
base::Callback<std::unique_ptr<ServiceManagerConnection>(void)>;
@@ -144,6 +147,12 @@ class CONTENT_EXPORT ServiceManagerConnection {
virtual void AddServiceRequestHandler(
const std::string& name,
const ServiceRequestHandler& handler) = 0;
+
+ // Registers a callback to be run when the service_manager::Service
+ // implementation on the IO thread receives OnConnect(). Returns an id that
+ // can be passed to RemoveOnConnectHandler(), starting at 1.
+ virtual int AddOnConnectHandler(const OnConnectHandler& handler) = 0;
+ virtual void RemoveOnConnectHandler(int id) = 0;
};
} // namespace content
« no previous file with comments | « content/public/app/mojo/content_renderer_manifest.json ('k') | content/public/test/mock_render_thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698