OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 // Next MinVersion: 5 | 5 // Next MinVersion: 6 |
6 | 6 |
7 module arc.mojom; | 7 module arc.mojom; |
8 | 8 |
9 import "bitmap.mojom"; | 9 import "bitmap.mojom"; |
10 | 10 |
11 // These values must be matched with the NOTIFICATION_EVENT_* constants in | 11 // These values must be matched with the NOTIFICATION_EVENT_* constants in |
12 // com.android.server.ArcNotificationListenerService. | 12 // com.android.server.ArcNotificationListenerService. |
13 enum ArcNotificationEvent { | 13 enum ArcNotificationEvent { |
14 BODY_CLICKED = 0, | 14 BODY_CLICKED = 0, |
15 CLOSED = 1, | 15 CLOSED = 1, |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
63 bool no_clear; | 63 bool no_clear; |
64 // Flag if the notification has FLAG_ONGOING_EVENT. | 64 // Flag if the notification has FLAG_ONGOING_EVENT. |
65 [MinVersion=1] | 65 [MinVersion=1] |
66 bool ongoing_event; | 66 bool ongoing_event; |
67 // Subtexts for list notifications. | 67 // Subtexts for list notifications. |
68 [MinVersion=3] | 68 [MinVersion=3] |
69 array<string>? texts; | 69 array<string>? texts; |
70 // Image for image notifications. | 70 // Image for image notifications. |
71 [MinVersion=3] | 71 [MinVersion=3] |
72 ArcBitmap? big_picture; | 72 ArcBitmap? big_picture; |
73 [MinVersion=5] | |
74 bool use_custom_notification; | |
yoshiki
2016/06/21 04:01:07
nit: please add a comment that this flag is valid
xiyuan
2016/06/21 14:38:43
Done.
| |
73 }; | 75 }; |
74 | 76 |
75 [MinVersion=2] | 77 [MinVersion=2] |
76 struct ArcToastData { | 78 struct ArcToastData { |
77 // Unique identifier | 79 // Unique identifier |
78 string id; | 80 string id; |
79 // Toast text. | 81 // Toast text. |
80 string? text; | 82 string? text; |
81 // Toast duration in milliseconds. If -1, the toast will be displayed until | 83 // Toast duration in milliseconds. If -1, the toast will be displayed until |
82 // the dismiss button is clicked. | 84 // the dismiss button is clicked. |
(...skipping 25 matching lines...) Expand all Loading... | |
108 | 110 |
109 // TODO(lhchavez): Migrate all request/response messages to Mojo. | 111 // TODO(lhchavez): Migrate all request/response messages to Mojo. |
110 interface NotificationsInstance { | 112 interface NotificationsInstance { |
111 // Establishes full-duplex communication with the host. | 113 // Establishes full-duplex communication with the host. |
112 Init(NotificationsHost host_ptr); | 114 Init(NotificationsHost host_ptr); |
113 | 115 |
114 // Sends an event from Chrome notification UI to Android. | 116 // Sends an event from Chrome notification UI to Android. |
115 // |event| is a type of occured event. | 117 // |event| is a type of occured event. |
116 SendNotificationEventToAndroid(string key, ArcNotificationEvent event); | 118 SendNotificationEventToAndroid(string key, ArcNotificationEvent event); |
117 }; | 119 }; |
OLD | NEW |