Enable gesture editing visibile in options menu.
[chromium-blink-merge.git] / content / common / push_messaging_messages.h
blob3849c5ab0021543ef8b56486a2640fe4ff99a7d3
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
3 // found in the LICENSE file.
5 // IPC messages for push messaging.
6 // Multiply-included message file, hence no include guard.
8 #include <stdint.h>
10 #include "content/public/common/push_messaging_status.h"
11 #include "ipc/ipc_message_macros.h"
12 #include "third_party/WebKit/public/platform/modules/push_messaging/WebPushError.h"
13 #include "third_party/WebKit/public/platform/modules/push_messaging/WebPushPermissionStatus.h"
14 #include "url/gurl.h"
16 #define IPC_MESSAGE_START PushMessagingMsgStart
18 IPC_ENUM_TRAITS_MAX_VALUE(content::PushRegistrationStatus,
19 content::PUSH_REGISTRATION_STATUS_LAST)
21 IPC_ENUM_TRAITS_MAX_VALUE(content::PushGetRegistrationStatus,
22 content::PUSH_GETREGISTRATION_STATUS_LAST)
24 IPC_ENUM_TRAITS_MAX_VALUE(
25 blink::WebPushPermissionStatus,
26 blink::WebPushPermissionStatus::WebPushPermissionStatusLast)
28 IPC_ENUM_TRAITS_MAX_VALUE(
29 blink::WebPushError::ErrorType,
30 blink::WebPushError::ErrorType::ErrorTypeLast)
32 // Messages sent from the browser to the child process.
34 IPC_MESSAGE_ROUTED2(PushMessagingMsg_SubscribeFromDocumentSuccess,
35 int32_t /* request_id */,
36 GURL /* push_endpoint */)
38 IPC_MESSAGE_CONTROL2(PushMessagingMsg_SubscribeFromWorkerSuccess,
39 int32_t /* request_id */,
40 GURL /* push_endpoint */)
42 IPC_MESSAGE_ROUTED2(PushMessagingMsg_SubscribeFromDocumentError,
43 int32_t /* request_id */,
44 content::PushRegistrationStatus /* status */)
46 IPC_MESSAGE_CONTROL2(PushMessagingMsg_SubscribeFromWorkerError,
47 int32_t /* request_id */,
48 content::PushRegistrationStatus /* status */)
50 IPC_MESSAGE_CONTROL2(PushMessagingMsg_UnsubscribeSuccess,
51 int32_t /* request_id */,
52 bool /* did_unsubscribe */)
54 IPC_MESSAGE_CONTROL3(PushMessagingMsg_UnsubscribeError,
55 int32_t /* request_id */,
56 blink::WebPushError::ErrorType /* error_type */,
57 std::string /* error_message */)
59 IPC_MESSAGE_CONTROL2(PushMessagingMsg_GetRegistrationSuccess,
60 int32_t /* request_id */,
61 GURL /* push_endpoint */)
63 IPC_MESSAGE_CONTROL2(PushMessagingMsg_GetRegistrationError,
64 int32_t /* request_id */,
65 content::PushGetRegistrationStatus /* status */)
67 IPC_MESSAGE_CONTROL2(PushMessagingMsg_GetPermissionStatusSuccess,
68 int32_t /* request_id */,
69 blink::WebPushPermissionStatus /* status */)
71 IPC_MESSAGE_CONTROL2(PushMessagingMsg_GetPermissionStatusError,
72 int32_t /* request_id */,
73 blink::WebPushError::ErrorType /* error_type */)
75 // Messages sent from the child process to the browser.
77 IPC_MESSAGE_CONTROL5(PushMessagingHostMsg_SubscribeFromDocument,
78 int32_t /* render_frame_id */,
79 int32_t /* request_id */,
80 std::string /* sender_id */,
81 bool /* user_visible */,
82 int64_t /* service_worker_registration_id */)
84 IPC_MESSAGE_CONTROL3(PushMessagingHostMsg_SubscribeFromWorker,
85 int32_t /* request_id */,
86 int64_t /* service_worker_registration_id */,
87 bool /* user_visible */)
89 IPC_MESSAGE_CONTROL2(PushMessagingHostMsg_Unsubscribe,
90 int32_t /* request_id */,
91 int64_t /* service_worker_registration_id */)
93 IPC_MESSAGE_CONTROL2(PushMessagingHostMsg_GetRegistration,
94 int32_t /* request_id */,
95 int64_t /* service_worker_registration_id */)
97 IPC_MESSAGE_CONTROL3(PushMessagingHostMsg_GetPermissionStatus,
98 int32_t /* request_id */,
99 int64_t /* service_worker_registration_id */,
100 bool /* user_visible */)