Index: content/browser/service_worker/service_worker_register_job.h |
diff --git a/content/browser/service_worker/service_worker_register_job.h b/content/browser/service_worker/service_worker_register_job.h |
index fcfa47ea1f339a5ec54adfb420b7b77d7120c644..2630585a645047031f2b2b76c1929f5f3a3b2533 100644 |
--- a/content/browser/service_worker/service_worker_register_job.h |
+++ b/content/browser/service_worker/service_worker_register_job.h |
@@ -55,11 +55,11 @@ class ServiceWorkerRegisterJob : public ServiceWorkerRegisterJobBase, |
virtual ~ServiceWorkerRegisterJob(); |
// Registers a callback to be called when the promise would resolve (whether |
- // successfully or not). Multiple callbacks may be registered. If |process_id| |
- // is not -1, it's added to the existing clients when deciding in which |
- // process to create the Service Worker instance. If there are no existing |
- // clients, a new RenderProcessHost will be created. |
- void AddCallback(const RegistrationCallback& callback, int process_id); |
+ // successfully or not). Multiple callbacks may be registered. |
+ // If |provider_host| is not NULL, it's added to the pending provider host |
+ // list which will provide process to create the Service Worker instance. |
+ void AddCallback(const RegistrationCallback& callback, |
+ ServiceWorkerProviderHost* provider_host); |
// ServiceWorkerRegisterJobBase implementation: |
virtual void Start() OVERRIDE; |
@@ -148,6 +148,8 @@ class ServiceWorkerRegisterJob : public ServiceWorkerRegisterJobBase, |
void AssociateProviderHostsToRegistration( |
ServiceWorkerRegistration* registration); |
+ void AssociateProviderHostsToPendingRegistration( |
+ ServiceWorkerRegistration* registration); |
// The ServiceWorkerContextCore object should always outlive this. |
base::WeakPtr<ServiceWorkerContextCore> context_; |
@@ -156,7 +158,8 @@ class ServiceWorkerRegisterJob : public ServiceWorkerRegisterJobBase, |
const GURL pattern_; |
const GURL script_url_; |
std::vector<RegistrationCallback> callbacks_; |
- std::vector<int> pending_process_ids_; |
+ std::vector<base::WeakPtr<ServiceWorkerProviderHost> > |
+ pending_provider_hosts_; |
Phase phase_; |
Internal internal_; |
bool is_promise_resolved_; |