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

Unified Diff: chrome/common/render_messages_internal.h

Issue 390017: Added lifecycle management and sharing support for SharedWorkers. SharedWorkers (Closed)
Patch Set: Changed WebWorkerBase not not call a virtual function from the destructor Created 11 years, 1 month 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: chrome/common/render_messages_internal.h
diff --git a/chrome/common/render_messages_internal.h b/chrome/common/render_messages_internal.h
index 2ad32ab347151179c60a9eebb14c2dbc2b87526b..a5c5f35f7a58510d7a9f572c5c5992b0bb041ee5 100644
--- a/chrome/common/render_messages_internal.h
+++ b/chrome/common/render_messages_internal.h
@@ -1745,6 +1745,27 @@ IPC_BEGIN_MESSAGES(ViewHost)
int /* render_view_route_id */,
int /* route_id */)
+ // This message is sent to the browser to see if an instance of this shared
+ // worker already exists (returns route_id != MSG_ROUTING_NONE). This route
+ // id can be used to forward messages to the worker via ForwardToWorker. If a
+ // non-empty name is passed, also validates that the url matches the url of
+ // the existing worker. If a matching worker is found, the passed-in
+ // document_id is associated with that worker, to ensure that the worker
+ // stays alive until the document is detached.
+ IPC_SYNC_MESSAGE_CONTROL3_2(ViewHostMsg_LookupSharedWorker,
+ GURL /* url */,
+ string16 /* name */,
+ unsigned long long /* document_id */,
+ int /* route_id */,
+ bool /* url_mismatch */)
+
+ // A renderer sends this to the browser process when a document has been
+ // detached. The browser will use this to constrain the lifecycle of worker
+ // processes (SharedWorkers are shut down when their last associated document
+ // is detached).
+ IPC_MESSAGE_CONTROL1(ViewHostMsg_DocumentDetached,
+ unsigned long long /* document_id */)
+
// A message sent to the browser on behalf of a renderer which wants to show
// a desktop notification.
IPC_MESSAGE_ROUTED3(ViewHostMsg_ShowDesktopNotification,

Powered by Google App Engine
This is Rietveld 408576698