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

Side by Side Diff: content/browser/service_worker/service_worker_provider_host.h

Issue 1141813002: ServiceWorker: Introduce ServiceWorkerMessageEvent to replace MessageEvent (2/3). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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
« no previous file with comments | « no previous file | content/browser/service_worker/service_worker_provider_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_
7 7
8 #include <set> 8 #include <set>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 // new registration association while a navigation is occurring and 151 // new registration association while a navigation is occurring and
152 // an existing registration is being looked for. 152 // an existing registration is being looked for.
153 void SetAllowAssociation(bool allow) { allow_association_ = allow; } 153 void SetAllowAssociation(bool allow) { allow_association_ = allow; }
154 154
155 // Returns true if the context referred to by this host (i.e. |context_|) is 155 // Returns true if the context referred to by this host (i.e. |context_|) is
156 // still alive. 156 // still alive.
157 bool IsContextAlive(); 157 bool IsContextAlive();
158 158
159 // Dispatches message event to the document. 159 // Dispatches message event to the document.
160 void PostMessage( 160 void PostMessage(
161 ServiceWorkerVersion* version,
161 const base::string16& message, 162 const base::string16& message,
162 const std::vector<TransferredMessagePort>& sent_message_ports); 163 const std::vector<TransferredMessagePort>& sent_message_ports);
163 164
164 // Activates the WebContents associated with 165 // Activates the WebContents associated with
165 // { render_process_id_, route_id_ }. 166 // { render_process_id_, route_id_ }.
166 // Runs the |callback| with the updated ServiceWorkerClientInfo in parameter. 167 // Runs the |callback| with the updated ServiceWorkerClientInfo in parameter.
167 void Focus(const GetClientInfoCallback& callback); 168 void Focus(const GetClientInfoCallback& callback);
168 169
169 // Asks the renderer to send back the document information. 170 // Asks the renderer to send back the document information.
170 void GetWindowClientInfo(const GetClientInfoCallback& callback) const; 171 void GetWindowClientInfo(const GetClientInfoCallback& callback) const;
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 bool allow_association_; 311 bool allow_association_;
311 312
312 std::vector<base::Closure> queued_events_; 313 std::vector<base::Closure> queued_events_;
313 314
314 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerProviderHost); 315 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerProviderHost);
315 }; 316 };
316 317
317 } // namespace content 318 } // namespace content
318 319
319 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_ 320 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_PROVIDER_HOST_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/service_worker/service_worker_provider_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698