| 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 // Messages for platform-native notifications using the Web Notification API. | 5 // Messages for platform-native notifications using the Web Notification API. |
| 6 // Multiply-included message file, hence no include guard. | 6 // Multiply-included message file, hence no include guard. |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 IPC_STRUCT_TRAITS_BEGIN(content::NotificationResources) | 64 IPC_STRUCT_TRAITS_BEGIN(content::NotificationResources) |
| 65 IPC_STRUCT_TRAITS_MEMBER(image) | 65 IPC_STRUCT_TRAITS_MEMBER(image) |
| 66 IPC_STRUCT_TRAITS_MEMBER(notification_icon) | 66 IPC_STRUCT_TRAITS_MEMBER(notification_icon) |
| 67 IPC_STRUCT_TRAITS_MEMBER(badge) | 67 IPC_STRUCT_TRAITS_MEMBER(badge) |
| 68 IPC_STRUCT_TRAITS_MEMBER(action_icons) | 68 IPC_STRUCT_TRAITS_MEMBER(action_icons) |
| 69 IPC_STRUCT_TRAITS_END() | 69 IPC_STRUCT_TRAITS_END() |
| 70 | 70 |
| 71 // Messages sent from the browser to the renderer. | 71 // Messages sent from the browser to the renderer. |
| 72 | 72 |
| 73 // Informs the renderer that the browser has displayed the notification. | 73 // Informs the renderer that the browser has displayed the notification. |
| 74 IPC_MESSAGE_CONTROL1(PlatformNotificationMsg_DidShow, | 74 IPC_MESSAGE_CONTROL2(PlatformNotificationMsg_DidShow, |
| 75 int /* notification_id */) | 75 int /* non_persistent_notification_id */, |
| 76 std::string /* notification_id */) |
| 76 | 77 |
| 77 // Informs the renderer that the notification has been closed. | 78 // Informs the renderer that the notification has been closed. |
| 78 IPC_MESSAGE_CONTROL1(PlatformNotificationMsg_DidClose, | 79 IPC_MESSAGE_CONTROL2(PlatformNotificationMsg_DidClose, |
| 79 int /* notification_id */) | 80 int /* non_persistent_notification_id */, |
| 81 std::string /* notification_id */) |
| 80 | 82 |
| 81 // Informs the renderer that the notification has been clicked on. | 83 // Informs the renderer that the notification has been clicked on. |
| 82 IPC_MESSAGE_CONTROL1(PlatformNotificationMsg_DidClick, | 84 IPC_MESSAGE_CONTROL1(PlatformNotificationMsg_DidClick, |
| 83 int /* notification_id */) | 85 int /* non_persistent_notification_id */) |
| 84 | 86 |
| 85 // Reply to PlatformNotificationHostMsg_ShowPersistent indicating that a | 87 // Reply to PlatformNotificationHostMsg_ShowPersistent indicating that a |
| 86 // persistent notification has been shown on the platform (if |success| is | 88 // persistent notification has been shown on the platform (if |success| is |
| 87 // true), or that an unspecified error occurred. | 89 // true), or that an unspecified error occurred. |
| 88 IPC_MESSAGE_CONTROL2(PlatformNotificationMsg_DidShowPersistent, | 90 IPC_MESSAGE_CONTROL2(PlatformNotificationMsg_DidShowPersistent, |
| 89 int /* request_id */, | 91 int /* request_id */, |
| 90 bool /* success */) | 92 bool /* success */) |
| 91 | 93 |
| 92 // Reply to PlatformNotificationHostMsg_GetNotifications sharing a vector of | 94 // Reply to PlatformNotificationHostMsg_GetNotifications sharing a vector of |
| 93 // available notifications per the request's constraints. | 95 // available notifications per the request's constraints. |
| (...skipping 21 matching lines...) Expand all Loading... |
| 115 | 117 |
| 116 IPC_MESSAGE_CONTROL4(PlatformNotificationHostMsg_GetNotifications, | 118 IPC_MESSAGE_CONTROL4(PlatformNotificationHostMsg_GetNotifications, |
| 117 int /* request_id */, | 119 int /* request_id */, |
| 118 int64_t /* service_worker_registration_id */, | 120 int64_t /* service_worker_registration_id */, |
| 119 GURL /* origin */, | 121 GURL /* origin */, |
| 120 std::string /* filter_tag */) | 122 std::string /* filter_tag */) |
| 121 | 123 |
| 122 IPC_MESSAGE_CONTROL3(PlatformNotificationHostMsg_Close, | 124 IPC_MESSAGE_CONTROL3(PlatformNotificationHostMsg_Close, |
| 123 GURL /* origin */, | 125 GURL /* origin */, |
| 124 std::string /* tag */, | 126 std::string /* tag */, |
| 125 int /* non_persistent_notification_id */) | |
| 126 | |
| 127 IPC_MESSAGE_CONTROL3(PlatformNotificationHostMsg_ClosePersistent, | |
| 128 GURL /* origin */, | |
| 129 std::string /* tag */, | |
| 130 std::string /* notification_id */) | 127 std::string /* notification_id */) |
| OLD | NEW |