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

Side by Side Diff: content/browser/service_worker/service_worker_internals_ui.cc

Issue 225403014: ServiceWorker: propagate provider_id to the browser process in .register + int32/int cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 6 years, 8 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 | Annotate | Revision Log
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 #include "content/browser/service_worker/service_worker_internals_ui.h" 5 #include "content/browser/service_worker/service_worker_internals_ui.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 context_path)); 277 context_path));
278 } 278 }
279 279
280 void ServiceWorkerInternalsUI::OperationProxy::UnregisterOnIOThread( 280 void ServiceWorkerInternalsUI::OperationProxy::UnregisterOnIOThread(
281 scoped_refptr<ServiceWorkerContextWrapper> context, 281 scoped_refptr<ServiceWorkerContextWrapper> context,
282 const GURL& scope) { 282 const GURL& scope) {
283 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 283 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
284 context->context()->UnregisterServiceWorker( 284 context->context()->UnregisterServiceWorker(
285 scope, 285 scope,
286 0, // render process id? 286 0, // render process id?
287 NULL, // provider_host
287 base::Bind(&ServiceWorkerInternalsUI::OperationProxy::OperationComplete, 288 base::Bind(&ServiceWorkerInternalsUI::OperationProxy::OperationComplete,
288 this)); 289 this));
289 } 290 }
290 291
291 void ServiceWorkerInternalsUI::OperationProxy::StartWorkerOnIOThread( 292 void ServiceWorkerInternalsUI::OperationProxy::StartWorkerOnIOThread(
292 scoped_refptr<ServiceWorkerContextWrapper> context, 293 scoped_refptr<ServiceWorkerContextWrapper> context,
293 const GURL& scope) { 294 const GURL& scope) {
294 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 295 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
295 // TODO(alecflett): Add support for starting/stopping workers for 296 // TODO(alecflett): Add support for starting/stopping workers for
296 // pending versions too. 297 // pending versions too.
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 ServiceWorkerVersion::ACTIVE) { 473 ServiceWorkerVersion::ACTIVE) {
473 registration->active_version()->DispatchSyncEvent(base::Bind( 474 registration->active_version()->DispatchSyncEvent(base::Bind(
474 &ServiceWorkerInternalsUI::OperationProxy::OperationComplete, this)); 475 &ServiceWorkerInternalsUI::OperationProxy::OperationComplete, this));
475 return; 476 return;
476 } 477 }
477 478
478 OperationComplete(SERVICE_WORKER_ERROR_FAILED); 479 OperationComplete(SERVICE_WORKER_ERROR_FAILED);
479 } 480 }
480 481
481 } // namespace content 482 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698