| 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 CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ | 5 #ifndef CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ |
| 6 #define CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ | 6 #define CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 const blink::WebString& filter_tag, | 56 const blink::WebString& filter_tag, |
| 57 blink::WebServiceWorkerRegistration* service_worker_registration, | 57 blink::WebServiceWorkerRegistration* service_worker_registration, |
| 58 blink::WebNotificationGetCallbacks* callbacks) override; | 58 blink::WebNotificationGetCallbacks* callbacks) override; |
| 59 void close(blink::WebNotificationDelegate* delegate) override; | 59 void close(blink::WebNotificationDelegate* delegate) override; |
| 60 void closePersistent(const blink::WebSecurityOrigin& origin, | 60 void closePersistent(const blink::WebSecurityOrigin& origin, |
| 61 int64_t persistent_notification_id) override; | 61 int64_t persistent_notification_id) override; |
| 62 void notifyDelegateDestroyed( | 62 void notifyDelegateDestroyed( |
| 63 blink::WebNotificationDelegate* delegate) override; | 63 blink::WebNotificationDelegate* delegate) override; |
| 64 blink::WebNotificationPermission checkPermission( | 64 blink::WebNotificationPermission checkPermission( |
| 65 const blink::WebSecurityOrigin& origin) override; | 65 const blink::WebSecurityOrigin& origin) override; |
| 66 size_t maxActions() override; | |
| 67 | 66 |
| 68 // Called by the NotificationDispatcher. | 67 // Called by the NotificationDispatcher. |
| 69 bool OnMessageReceived(const IPC::Message& message); | 68 bool OnMessageReceived(const IPC::Message& message); |
| 70 | 69 |
| 71 private: | 70 private: |
| 72 NotificationManager(ThreadSafeSender* thread_safe_sender, | 71 NotificationManager(ThreadSafeSender* thread_safe_sender, |
| 73 NotificationDispatcher* notification_dispatcher); | 72 NotificationDispatcher* notification_dispatcher); |
| 74 | 73 |
| 75 // IPC message handlers. | 74 // IPC message handlers. |
| 76 void OnDidShow(int notification_id); | 75 void OnDidShow(int notification_id); |
| (...skipping 17 matching lines...) Expand all Loading... |
| 94 | 93 |
| 95 // Map to store the delegate associated with a notification request Id. | 94 // Map to store the delegate associated with a notification request Id. |
| 96 std::map<int, blink::WebNotificationDelegate*> active_page_notifications_; | 95 std::map<int, blink::WebNotificationDelegate*> active_page_notifications_; |
| 97 | 96 |
| 98 DISALLOW_COPY_AND_ASSIGN(NotificationManager); | 97 DISALLOW_COPY_AND_ASSIGN(NotificationManager); |
| 99 }; | 98 }; |
| 100 | 99 |
| 101 } // namespace content | 100 } // namespace content |
| 102 | 101 |
| 103 #endif // CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ | 102 #endif // CONTENT_CHILD_NOTIFICATIONS_NOTIFICATION_MANAGER_H_ |
| OLD | NEW |