| OLD | NEW |
| 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 #ifndef WebNotificationManager_h | 5 #ifndef WebNotificationManager_h |
| 6 #define WebNotificationManager_h | 6 #define WebNotificationManager_h |
| 7 | 7 |
| 8 #include "public/platform/WebCallbacks.h" | 8 #include "public/platform/WebCallbacks.h" |
| 9 #include "public/platform/WebString.h" | 9 #include "public/platform/WebString.h" |
| 10 #include "public/platform/WebVector.h" | 10 #include "public/platform/WebVector.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 virtual void showPersistent(const WebSecurityOrigin&, | 48 virtual void showPersistent(const WebSecurityOrigin&, |
| 49 const WebNotificationData&, | 49 const WebNotificationData&, |
| 50 std::unique_ptr<WebNotificationResources>, | 50 std::unique_ptr<WebNotificationResources>, |
| 51 WebServiceWorkerRegistration*, | 51 WebServiceWorkerRegistration*, |
| 52 WebNotificationShowCallbacks*) = 0; | 52 WebNotificationShowCallbacks*) = 0; |
| 53 | 53 |
| 54 // Asynchronously gets the persistent notifications belonging to the Service | 54 // Asynchronously gets the persistent notifications belonging to the Service |
| 55 // Worker Registration. If |filterTag| is not an empty string, only the | 55 // Worker Registration. If |filterTag| is not an empty string, only the |
| 56 // notification with the given tag will be considered. Will take ownership of | 56 // notification with the given tag will be considered. Will take ownership of |
| 57 // the WebNotificationGetCallbacks object. | 57 // the WebNotificationGetCallbacks object. |
| 58 virtual void getNotifications(const WebString& filterTag, | 58 virtual void getNotifications( |
| 59 WebServiceWorkerRegistration*, | 59 const WebString& filterTag, |
| 60 WebNotificationGetCallbacks*) = 0; | 60 WebServiceWorkerRegistration*, |
| 61 std::unique_ptr<WebNotificationGetCallbacks>) = 0; |
| 61 | 62 |
| 62 // Closes a notification previously shown, and removes it if being shown. | 63 // Closes a notification previously shown, and removes it if being shown. |
| 63 virtual void close(WebNotificationDelegate*) = 0; | 64 virtual void close(WebNotificationDelegate*) = 0; |
| 64 | 65 |
| 65 // Closes a persistent notification identified by its notification Id. | 66 // Closes a persistent notification identified by its notification Id. |
| 66 virtual void closePersistent(const WebSecurityOrigin&, | 67 virtual void closePersistent(const WebSecurityOrigin&, |
| 67 const WebString& tag, | 68 const WebString& tag, |
| 68 const WebString& notificationId) = 0; | 69 const WebString& notificationId) = 0; |
| 69 | 70 |
| 70 // Indicates that the delegate object is being destroyed, and must no longer | 71 // Indicates that the delegate object is being destroyed, and must no longer |
| 71 // be used by the embedder to dispatch events. | 72 // be used by the embedder to dispatch events. |
| 72 virtual void notifyDelegateDestroyed(WebNotificationDelegate*) = 0; | 73 virtual void notifyDelegateDestroyed(WebNotificationDelegate*) = 0; |
| 73 }; | 74 }; |
| 74 | 75 |
| 75 } // namespace blink | 76 } // namespace blink |
| 76 | 77 |
| 77 #endif // WebNotificationManager_h | 78 #endif // WebNotificationManager_h |
| OLD | NEW |