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

Side by Side Diff: Source/modules/serviceworkers/WaitUntilObserver.cpp

Issue 779563003: [POC-WIP] Link window focus tokens with ExecutionContext. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years 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
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 "config.h" 5 #include "config.h"
6 #include "modules/serviceworkers/WaitUntilObserver.h" 6 #include "modules/serviceworkers/WaitUntilObserver.h"
7 7
8 #include "bindings/core/v8/ScriptFunction.h" 8 #include "bindings/core/v8/ScriptFunction.h"
9 #include "bindings/core/v8/ScriptPromise.h" 9 #include "bindings/core/v8/ScriptPromise.h"
10 #include "bindings/core/v8/ScriptValue.h" 10 #include "bindings/core/v8/ScriptValue.h"
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 WebServiceWorkerEventResult result = m_hasError ? WebServiceWorkerEventResul tRejected : WebServiceWorkerEventResultCompleted; 127 WebServiceWorkerEventResult result = m_hasError ? WebServiceWorkerEventResul tRejected : WebServiceWorkerEventResultCompleted;
128 switch (m_type) { 128 switch (m_type) {
129 case Activate: 129 case Activate:
130 client->didHandleActivateEvent(m_eventID, result); 130 client->didHandleActivateEvent(m_eventID, result);
131 break; 131 break;
132 case Install: 132 case Install:
133 client->didHandleInstallEvent(m_eventID, result); 133 client->didHandleInstallEvent(m_eventID, result);
134 break; 134 break;
135 case NotificationClick: 135 case NotificationClick:
136 client->didHandleNotificationClickEvent(m_eventID, result); 136 client->didHandleNotificationClickEvent(m_eventID, result);
137 executionContext()->consumeWindowFocusToken();
137 break; 138 break;
138 case Push: 139 case Push:
139 client->didHandlePushEvent(m_eventID, result); 140 client->didHandlePushEvent(m_eventID, result);
140 break; 141 break;
141 } 142 }
142 observeContext(0); 143 observeContext(0);
143 } 144 }
144 145
145 } // namespace blink 146 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/serviceworkers/ServiceWorkerGlobalScopeClient.h ('k') | Source/web/ServiceWorkerGlobalScopeClientImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698