4 * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
6 * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
22 #ifndef __NOTIFICATION_TYPE_H__
23 #define __NOTIFICATION_TYPE_H__
29 #ifndef NOTIFICATION_DEPRECATED_API
31 #define NOTIFICATION_DEPRECATED_API __attribute__((deprecated))
33 #define NOTIFICATION_DEPRECATED_API
38 * @file notification_type.h
39 * @brief This file contains type definitions and enumerations for Notification API.
43 * @addtogroup NOTIFICATION_MODULE
48 * @brief Enumeration for notification layout type.
51 typedef enum _notification_ly_type {
52 NOTIFICATION_LY_NONE = 0,
54 NOTIFICATION_LY_NOTI_EVENT_SINGLE,
55 /**< Layout for notification. Used to inform single event*/
56 NOTIFICATION_LY_NOTI_EVENT_MULTIPLE,
57 /**< Layout for notification. Used to inform multiple event*/
58 NOTIFICATION_LY_NOTI_THUMBNAIL,
59 /**< Layout for notification. Used to display images*/
60 NOTIFICATION_LY_ONGOING_EVENT,
61 /**< Layout for ongoing notification. Used to display text message*/
62 NOTIFICATION_LY_ONGOING_PROGRESS,
63 /**< Layout for ongoing notification. Used to display progress*/
66 } notification_ly_type_e;
69 * @brief Enumeration for notification lauch option type.
72 typedef enum _notification_launch_option_type {
73 NOTIFICATION_LAUNCH_OPTION_APP_CONTROL = 1,
74 /**< launching with app control */
75 } notification_launch_option_type;
78 * @brief Enumeration for event type on notification.
81 typedef enum _notification_event_type {
82 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_1 = 0, /** < Event type : Click on button 1 */
83 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_2 = 1, /** < Event type : Click on button 2 */
84 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_3 = 2, /** < Event type : Click on button 3 */
85 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_4 = 3, /** < Event type : Click on button 4 */
86 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_5 = 4, /** < Event type : Click on button 5 */
87 NOTIFICATION_EVENT_TYPE_CLICK_ON_BUTTON_6 = 5, /** < Event type : Click on button 6 */
88 NOTIFICATION_EVENT_TYPE_CLICK_ON_ICON = 6, /** < Event type : Click on icon */
89 NOTIFICATION_EVENT_TYPE_CLICK_ON_THUMBNAIL = 7, /** < Event type : Click on thumbnail */
90 NOTIFICATION_EVENT_TYPE_MAX,
91 } notification_event_type_e;
94 * @brief Enumeration for notification sound type.
97 typedef enum _notification_sound_type {
98 NOTIFICATION_SOUND_TYPE_NONE = -1,
99 /**< Default value. no sound */
100 NOTIFICATION_SOUND_TYPE_DEFAULT = 0,
101 /**< Default sound */
102 NOTIFICATION_SOUND_TYPE_USER_DATA,
103 /**< User sound data */
104 NOTIFICATION_SOUND_TYPE_MAX,
105 } notification_sound_type_e;
108 * @brief Enumeration for notification vibration type.
111 typedef enum _notification_vibration_type {
112 NOTIFICATION_VIBRATION_TYPE_NONE = -1,
113 /**< Default value. No vibration */
114 NOTIFICATION_VIBRATION_TYPE_DEFAULT = 0,/**< Default vibrate pattern */
115 NOTIFICATION_VIBRATION_TYPE_USER_DATA,
116 /**< User vibration data */
117 NOTIFICATION_VIBRATION_TYPE_MAX,
118 } notification_vibration_type_e;
121 * @brief Enumeration for notification LED operation.
124 typedef enum _notification_led_op {
125 NOTIFICATION_LED_OP_OFF = -1,
126 /**< Default value. Disable the LED notification */
127 NOTIFICATION_LED_OP_ON = 0,/**< Turn on the LED with default color */
128 NOTIFICATION_LED_OP_ON_CUSTOM_COLOR,
129 /**< Turn on the LED with custom color */
130 NOTIFICATION_LED_OP_MAX,/**< Max flag */
131 } notification_led_op_e;
134 * @brief This will be deprecated.
137 typedef enum _notification_count_display_type {
138 NOTIFICATION_COUNT_DISPLAY_TYPE_NONE = -1,
139 NOTIFICATION_COUNT_DISPLAY_TYPE_LEFT = 0, /**< The number is placed to left */
140 NOTIFICATION_COUNT_DISPLAY_TYPE_IN, /**< The number is placed to center */
141 NOTIFICATION_COUNT_DISPLAY_TYPE_RIGHT, /**< The number is placed to right */
142 NOTIFICATION_COUNT_DISPLAY_TYPE_MAX,
143 } notification_count_display_type_e;
146 * @brief Enumeration for notification text type.
149 typedef enum _notification_text_type {
150 NOTIFICATION_TEXT_TYPE_NONE = -1,
151 NOTIFICATION_TEXT_TYPE_TITLE = 0,
153 NOTIFICATION_TEXT_TYPE_CONTENT,
155 NOTIFICATION_TEXT_TYPE_CONTENT_FOR_DISPLAY_OPTION_IS_OFF,
156 /**< Content for content display option is off of the Settings */
157 NOTIFICATION_TEXT_TYPE_EVENT_COUNT,
158 /**< Text to display event count */
159 NOTIFICATION_TEXT_TYPE_INFO_1,
160 /**< Box contents 1 */
161 NOTIFICATION_TEXT_TYPE_INFO_SUB_1,
162 /**< Box contents 1-1 */
163 NOTIFICATION_TEXT_TYPE_INFO_2,
164 /**< Box contents 2 */
165 NOTIFICATION_TEXT_TYPE_INFO_SUB_2,
166 /**< Box contents 2-1 */
167 NOTIFICATION_TEXT_TYPE_INFO_3,
168 /**< Box contents 3 */
169 NOTIFICATION_TEXT_TYPE_INFO_SUB_3,
170 /**< Box contents 3-1 */
171 NOTIFICATION_TEXT_TYPE_GROUP_TITLE,
173 NOTIFICATION_TEXT_TYPE_GROUP_CONTENT,
174 /**< Group content */
175 NOTIFICATION_TEXT_TYPE_GROUP_CONTENT_FOR_DISPLAY_OPTION_IS_OFF,
176 /**< Group content for content display option is off of the Settings */
177 NOTIFICATION_TEXT_TYPE_BUTTON_1,
178 /**< Text on button 1 */
179 NOTIFICATION_TEXT_TYPE_BUTTON_2,
180 /**< Text on button 2 */
181 NOTIFICATION_TEXT_TYPE_BUTTON_3,
182 /**< Text on button 3 */
183 NOTIFICATION_TEXT_TYPE_BUTTON_4,
184 /**< Text on button 4 */
185 NOTIFICATION_TEXT_TYPE_BUTTON_5,
186 /**< Text on button 5 */
187 NOTIFICATION_TEXT_TYPE_BUTTON_6,
188 /**< Text on button 6 */
189 NOTIFICATION_TEXT_TYPE_MAX,
190 } notification_text_type_e;
193 * @brief Enumeration for image type.
196 typedef enum _notification_image_type {
197 NOTIFICATION_IMAGE_TYPE_NONE = -1,
198 NOTIFICATION_IMAGE_TYPE_ICON = 0,
200 NOTIFICATION_IMAGE_TYPE_ICON_FOR_INDICATOR,
201 /**< Indicator icon */
202 NOTIFICATION_IMAGE_TYPE_ICON_FOR_LOCK,
203 /**< Lock screen icon */
204 NOTIFICATION_IMAGE_TYPE_THUMBNAIL,
206 NOTIFICATION_IMAGE_TYPE_THUMBNAIL_FOR_LOCK,
207 /**< Lock screen thumbnail */
208 NOTIFICATION_IMAGE_TYPE_ICON_SUB,
210 NOTIFICATION_IMAGE_TYPE_BACKGROUND,
211 /**< image displayed on background */
212 NOTIFICATION_IMAGE_TYPE_LIST_1,
213 /**< Image for thumbnail list */
214 NOTIFICATION_IMAGE_TYPE_LIST_2,
215 /**< Image for thumbnail list */
216 NOTIFICATION_IMAGE_TYPE_LIST_3,
217 /**< Image for thumbnail list */
218 NOTIFICATION_IMAGE_TYPE_LIST_4,
219 /**< Image for thumbnail list */
220 NOTIFICATION_IMAGE_TYPE_LIST_5,
221 /**< Image for thumbnail list */
222 NOTIFICATION_IMAGE_TYPE_BUTTON_1,
223 /**< Image for button 1 */
224 NOTIFICATION_IMAGE_TYPE_BUTTON_2,
225 /**< Image for button 2 */
226 NOTIFICATION_IMAGE_TYPE_BUTTON_3,
227 /**< Image for button 3 */
228 NOTIFICATION_IMAGE_TYPE_BUTTON_4,
229 /**< Image for button 4 */
230 NOTIFICATION_IMAGE_TYPE_BUTTON_5,
231 /**< Image for button 5 */
232 NOTIFICATION_IMAGE_TYPE_BUTTON_6,
233 /**< Image for button 6 */
234 NOTIFICATION_IMAGE_TYPE_MAX,
235 } notification_image_type_e;
238 * @brief Enumeration for application execution type.
241 typedef enum _notification_execute_type {
242 NOTIFICATION_EXECUTE_TYPE_NONE = -1,
244 NOTIFICATION_EXECUTE_TYPE_RESPONDING = 0,
245 /**< Responding action*/
246 NOTIFICATION_EXECUTE_TYPE_SINGLE_LAUNCH,/**< Launching when notification data is single */
247 NOTIFICATION_EXECUTE_TYPE_MULTI_LAUNCH,
248 /**< Launching when notification data is grouping(multi) */
249 NOTIFICATION_EXECUTE_TYPE_MAX,
251 } notification_execute_type_e;
254 * @brief Enumeration for notification type.
257 typedef enum _notification_type {
258 NOTIFICATION_TYPE_NONE = -1,
260 NOTIFICATION_TYPE_NOTI = 0,
261 /**< Notification type */
262 NOTIFICATION_TYPE_ONGOING,
264 NOTIFICATION_TYPE_MAX,
266 } notification_type_e;
269 * @brief Enumeration for Group ID.
272 enum _notification_group_id {
273 NOTIFICATION_GROUP_ID_NONE = -1,/**< Not Grouping */
274 NOTIFICATION_GROUP_ID_DEFAULT = 0,
275 /**< Notification that has same title is grouping */
279 * @brief Enumeration for Private ID.
282 enum _notification_priv_id {
283 NOTIFICATION_PRIV_ID_NONE = -1,
284 /**< Internally set priv_id */
288 * @brief Enumeration for notification property.
291 enum _notification_property {
292 NOTIFICATION_PROP_DISPLAY_ONLY_SIMMODE = 0x00000001,
293 /**< Display only SIM card inserted */
294 NOTIFICATION_PROP_DISABLE_APP_LAUNCH = 0x00000002,
295 /**< Disable application launch when it selected */
296 NOTIFICATION_PROP_DISABLE_AUTO_DELETE = 0x00000004,
297 /**< Disable auto delete when it selected */
298 NOTIFICATION_PROP_LAUNCH_UG = 0x00000008,
299 /**< Will be deprecated. Notification Tray should launch application using appsvc API */
300 NOTIFICATION_PROP_DISABLE_TICKERNOTI = 0x00000010,
301 /**< Will be deprecated. Use notification_set_display_applist API */
302 NOTIFICATION_PROP_PERMANENT_DISPLAY = 0x00000020,
303 /** < Will be deprecated. */
304 NOTIFICATION_PROP_DISABLE_UPDATE_ON_INSERT = 0x00000040,/**< Disable update when it inserted. */
305 NOTIFICATION_PROP_DISABLE_UPDATE_ON_DELETE = 0x00000080,/**< Disable update when it deleted. */
306 NOTIFICATION_PROP_VOLATILE_DISPLAY = 0x00000100,/**< Deleted when device is rebooted eventhough NOTIFICATION_TYPE_NOTI type */
310 * @brief Enumeration for display application list.
313 enum _notificaton_display_applist {
314 NOTIFICATION_DISPLAY_APP_NOTIFICATION_TRAY = 0x00000001,/**< Notification Tray(Quickpanel) */
315 NOTIFICATION_DISPLAY_APP_TICKER = 0x00000002,
316 /**< Ticker notification */
317 NOTIFICATION_DISPLAY_APP_LOCK = 0x00000004,
319 NOTIFICATION_DISPLAY_APP_INDICATOR = 0x00000008,/**< Indicator */
320 NOTIFICATION_DISPLAY_APP_HEADS_UP = 0x00000010,/**< Heads-up notification */
321 NOTIFICATION_DISPLAY_APP_ALL = 0xffffffff,
322 /**< All display application */
326 * @brief Enumeration for notification operation code.
329 typedef enum _notification_op_type {
330 NOTIFICATION_OP_NONE = 0, /**< Default */
331 NOTIFICATION_OP_INSERT = 1, /**< Notification inserted */
332 NOTIFICATION_OP_UPDATE, /**< Notification updated */
333 NOTIFICATION_OP_DELETE, /**< Notification deleted */
334 NOTIFICATION_OP_DELETE_ALL, /**< Notifications deleted */
335 NOTIFICATION_OP_REFRESH, /**< Deprecated */
336 NOTIFICATION_OP_SERVICE_READY, /**< Notification service is ready */
337 } notification_op_type_e;
340 * @brief Enumeration for notification operation data code
343 typedef enum _notification_op_data_type {
344 NOTIFICATION_OP_DATA_MIN = 0, /**< Default */
345 NOTIFICATION_OP_DATA_TYPE, /**< Operation type */
346 NOTIFICATION_OP_DATA_PRIV_ID, /**< Private ID */
347 NOTIFICATION_OP_DATA_NOTI, /**< Notification handler */
348 NOTIFICATION_OP_DATA_EXTRA_INFO_1, /**< Reserved */
349 NOTIFICATION_OP_DATA_EXTRA_INFO_2, /**< Reserved */
350 NOTIFICATION_OP_DATA_MAX, /**< Max flag */
351 } notification_op_data_type_e;
354 * @brief Enumeration for notification count position in the text.
357 typedef enum _notifcation_count_pos_type {
358 NOTIFICATION_COUNT_POS_NONE = -1,
359 /**< Count data is not displaying in the text */
360 NOTIFICATION_COUNT_POS_LEFT = 0,/**< Count data is displaying at the left of the text */
361 NOTIFICATION_COUNT_POS_IN,
362 /**< Count data is displaying in the text */
363 NOTIFICATION_COUNT_POS_RIGHT,
364 /**< Count data is displaying at the right of the text */
365 NOTIFICATION_COUNT_POS_MAX,
367 } notification_count_pos_type_e;
370 * @brief Enumeration for notification variable parameter type.
373 typedef enum _notification_variable_type {
374 NOTIFICATION_VARIABLE_TYPE_NONE = -1,
375 /**< Variable parameter type is NONE */
376 NOTIFICATION_VARIABLE_TYPE_INT = 0,
377 /**< Variable parameter type is int */
378 NOTIFICATION_VARIABLE_TYPE_DOUBLE,
379 /**< Variable parameter type is double */
380 NOTIFICATION_VARIABLE_TYPE_STRING,
381 /**< Variable parameter type is string */
382 NOTIFICATION_VARIABLE_TYPE_COUNT,
383 /**< Variable parameter type is count */
384 NOTIFICATION_VARIABLE_TYPE_MAX,
386 } notification_variable_type_e;
389 * @brief Notification handle.
392 typedef struct _notification *notification_h;
395 * @brief The structure for notification operation.
398 typedef struct _notification_op {
399 notification_op_type_e type; /**< Notification operation type */
400 int priv_id; /**< private ID */
401 int extra_info_1; /**< Reserved */
402 int extra_info_2; /**< Reserved */
403 notification_h noti; /**< Notification handler */
407 * @brief Enumeration for permission.
410 typedef enum notification_permission_type {
411 NOTIFICATION_PERMISSION_TYPE_NONE = 0,
412 NOTIFICATION_PERMISSION_TYPE_DELETE = 1,
413 NOTIFICATION_PERMISSION_TYPE_UPDATE = 2,
414 } notification_permission_type_e;
422 #endif /* __NOTIFICATION_TYPE_H__ */