| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "public/platform/modules/serviceworker/WebServiceWorkerClientsClaimCall
backs.h" | 38 #include "public/platform/modules/serviceworker/WebServiceWorkerClientsClaimCall
backs.h" |
| 39 #include "public/platform/modules/serviceworker/WebServiceWorkerClientsInfo.h" | 39 #include "public/platform/modules/serviceworker/WebServiceWorkerClientsInfo.h" |
| 40 #include "public/platform/modules/serviceworker/WebServiceWorkerEventResult.h" | 40 #include "public/platform/modules/serviceworker/WebServiceWorkerEventResult.h" |
| 41 #include "public/platform/modules/serviceworker/WebServiceWorkerSkipWaitingCallb
acks.h" | 41 #include "public/platform/modules/serviceworker/WebServiceWorkerSkipWaitingCallb
acks.h" |
| 42 #include "wtf/Forward.h" | 42 #include "wtf/Forward.h" |
| 43 #include "wtf/Noncopyable.h" | 43 #include "wtf/Noncopyable.h" |
| 44 #include <memory> | 44 #include <memory> |
| 45 | 45 |
| 46 namespace blink { | 46 namespace blink { |
| 47 | 47 |
| 48 struct WebPaymentAppResponse; |
| 48 struct WebServiceWorkerClientQueryOptions; | 49 struct WebServiceWorkerClientQueryOptions; |
| 49 class ExecutionContext; | 50 class ExecutionContext; |
| 50 class WebServiceWorkerResponse; | 51 class WebServiceWorkerResponse; |
| 51 class WebURL; | 52 class WebURL; |
| 52 class WorkerClients; | 53 class WorkerClients; |
| 53 | 54 |
| 54 // See WebServiceWorkerContextClient for documentation for the methods in this | 55 // See WebServiceWorkerContextClient for documentation for the methods in this |
| 55 // class. | 56 // class. |
| 56 class MODULES_EXPORT ServiceWorkerGlobalScopeClient | 57 class MODULES_EXPORT ServiceWorkerGlobalScopeClient |
| 57 : public Supplement<WorkerClients> { | 58 : public Supplement<WorkerClients> { |
| (...skipping 22 matching lines...) Expand all Loading... |
| 80 virtual void didHandleExtendableMessageEvent(int eventID, | 81 virtual void didHandleExtendableMessageEvent(int eventID, |
| 81 WebServiceWorkerEventResult, | 82 WebServiceWorkerEventResult, |
| 82 double eventDispatchTime) = 0; | 83 double eventDispatchTime) = 0; |
| 83 // Calling respondToFetchEvent without response means no response was | 84 // Calling respondToFetchEvent without response means no response was |
| 84 // provided by the service worker in the fetch events, so fallback to native. | 85 // provided by the service worker in the fetch events, so fallback to native. |
| 85 virtual void respondToFetchEvent(int fetchEventID, | 86 virtual void respondToFetchEvent(int fetchEventID, |
| 86 double eventDispatchTime) = 0; | 87 double eventDispatchTime) = 0; |
| 87 virtual void respondToFetchEvent(int fetchEventID, | 88 virtual void respondToFetchEvent(int fetchEventID, |
| 88 const WebServiceWorkerResponse&, | 89 const WebServiceWorkerResponse&, |
| 89 double eventDispatchTime) = 0; | 90 double eventDispatchTime) = 0; |
| 91 virtual void respondToPaymentRequestEvent(int eventID, |
| 92 const WebPaymentAppResponse&, |
| 93 double eventDispatchTime) = 0; |
| 90 virtual void didHandleFetchEvent(int fetchEventID, | 94 virtual void didHandleFetchEvent(int fetchEventID, |
| 91 WebServiceWorkerEventResult, | 95 WebServiceWorkerEventResult, |
| 92 double eventDispatchTime) = 0; | 96 double eventDispatchTime) = 0; |
| 93 virtual void didHandleInstallEvent(int installEventID, | 97 virtual void didHandleInstallEvent(int installEventID, |
| 94 WebServiceWorkerEventResult, | 98 WebServiceWorkerEventResult, |
| 95 double eventDispatchTime) = 0; | 99 double eventDispatchTime) = 0; |
| 96 virtual void didHandleNotificationClickEvent(int eventID, | 100 virtual void didHandleNotificationClickEvent(int eventID, |
| 97 WebServiceWorkerEventResult, | 101 WebServiceWorkerEventResult, |
| 98 double eventDispatchTime) = 0; | 102 double eventDispatchTime) = 0; |
| 99 virtual void didHandleNotificationCloseEvent(int eventID, | 103 virtual void didHandleNotificationCloseEvent(int eventID, |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 ServiceWorkerGlobalScopeClient() {} | 135 ServiceWorkerGlobalScopeClient() {} |
| 132 }; | 136 }; |
| 133 | 137 |
| 134 MODULES_EXPORT void provideServiceWorkerGlobalScopeClientToWorker( | 138 MODULES_EXPORT void provideServiceWorkerGlobalScopeClientToWorker( |
| 135 WorkerClients*, | 139 WorkerClients*, |
| 136 ServiceWorkerGlobalScopeClient*); | 140 ServiceWorkerGlobalScopeClient*); |
| 137 | 141 |
| 138 } // namespace blink | 142 } // namespace blink |
| 139 | 143 |
| 140 #endif // ServiceWorkerGlobalScopeClient_h | 144 #endif // ServiceWorkerGlobalScopeClient_h |
| OLD | NEW |