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

Unified Diff: content/browser/service_worker/service_worker_version.h

Issue 785133006: Enable messaging over a navigator.connect initiated channel. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@navigator-connect_serviceside
Patch Set: add empty line Created 6 years 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
Index: content/browser/service_worker/service_worker_version.h
diff --git a/content/browser/service_worker/service_worker_version.h b/content/browser/service_worker/service_worker_version.h
index eecf17effd72767d41e3cb3bf2dfcf5369337e44..2ea1ef737ec5cd0ef7fe6e73cb755c4f5f514f94 100644
--- a/content/browser/service_worker/service_worker_version.h
+++ b/content/browser/service_worker/service_worker_version.h
@@ -240,6 +240,20 @@ class CONTENT_EXPORT ServiceWorkerVersion
const CrossOriginConnectCallback& callback,
const CrossOriginServiceWorkerClient& client);
+ // Sends a cross origin message event to the associated embedded worker and
+ // asynchronously calls |callback| when the message was sent (or failed to
+ // sent).
+ // It is the responsibility of the code calling this method to make sure that
+ // any transferred message ports are put on hold while potentially a process
+ // for the service worker is spun up.
+ //
+ // This must be called when the status() is ACTIVATED.
+ void DispatchCrossOriginMessageEvent(
+ const CrossOriginServiceWorkerClient& client,
+ const base::string16& message,
+ const std::vector<int>& sent_message_port_ids,
+ const StatusCallback& callback);
+
// Adds and removes |provider_host| as a controllee of this ServiceWorker.
// A potential controllee is a host having the version as its .installing
// or .waiting version.
« no previous file with comments | « content/browser/renderer_host/render_process_host_impl.cc ('k') | content/browser/service_worker/service_worker_version.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698