summaryrefslogtreecommitdiffstats
path: root/content/content_browser.gypi
diff options
context:
space:
mode:
authorhoro <horo@chromium.org>2015-03-18 19:48:37 -0700
committerCommit bot <commit-bot@chromium.org>2015-03-19 02:49:28 +0000
commita6bb251916eec43cb0c7c6709c57aa6b4209be11 (patch)
tree472781169f79db37b4addb5aadf50bda69d6b750 /content/content_browser.gypi
parentbff9c2f7564000c3b912e18d70780d1a6263680f (diff)
downloadchromium_src-a6bb251916eec43cb0c7c6709c57aa6b4209be11.zip
chromium_src-a6bb251916eec43cb0c7c6709c57aa6b4209be11.tar.gz
chromium_src-a6bb251916eec43cb0c7c6709c57aa6b4209be11.tar.bz2
Revise ServiceWorker DevTools protocols.
After I landed https://codereview.chromium.org/985663002/ I noticed that there is some problems in ServiceWorker DevTools protocol. 1. ServiceWorkerHandler::ContextObserver can't get the state of ServiceWorkerVersion correctly. ServiceWorkerHandler::ContextObserver is using GetLiveVersion in OnVersionUpdated(). But when OnVersionUpdated() is called the live versions may already be deleted. This is because OnVersionUpdated() is called via ObserverListThreadSafe<ServiceWorkerContextObserver> in ServiceWorkerContextCore. So I change ServiceWorkerContextObserver::OnRunningStateChanged() and ServiceWorkerContextObserver::OnVersionStateChanged() to pass the new state and introduce OnNewLiveRegistration() and OnNewLiveVersion(). 2. We have to distinguish the ServiceWorkerRegistrations which are deleted from the storage. We shuold show the registrations which are already deleted from the storage but are still exist in the memory. This could happen when ServiceWorkerRegistration.unregister() has been called but there are still some controlled pages. So I will add isDeleted flag to ServiceWorkerRegistration DevTool's protocol. (https://codereview.chromium.org/996363002/) And we can stop using workerRegistrationDeleted event. 3. Stop using {active/waiting/installing}_version properties of ServiceWorkerRegistration in DevTools protocols. We send the all ServiceWorkerVersion infromation with workerVersionUpdated event and it has "state" properties. So we don't need {active/waiting/installing}_version properties of ServiceWorkerRegistration. This change depends on https://codereview.chromium.org/996363002/. BUG=466871 Review URL: https://codereview.chromium.org/998173002 Cr-Commit-Position: refs/heads/master@{#321277}
Diffstat (limited to 'content/content_browser.gypi')
-rw-r--r--content/content_browser.gypi2
1 files changed, 2 insertions, 0 deletions
diff --git a/content/content_browser.gypi b/content/content_browser.gypi
index ab9f15d..d213d74 100644
--- a/content/content_browser.gypi
+++ b/content/content_browser.gypi
@@ -1270,6 +1270,8 @@
'browser/service_worker/service_worker_context_observer.h',
'browser/service_worker/service_worker_context_request_handler.cc',
'browser/service_worker/service_worker_context_request_handler.h',
+ 'browser/service_worker/service_worker_context_watcher.cc',
+ 'browser/service_worker/service_worker_context_watcher.h',
'browser/service_worker/service_worker_context_wrapper.cc',
'browser/service_worker/service_worker_context_wrapper.h',
'browser/service_worker/service_worker_controllee_request_handler.cc',