summaryrefslogtreecommitdiff
path: root/src/notification_noti.c
diff options
context:
space:
mode:
authorseungha.son <seungha.son@samsung.com>2016-09-06 17:06:53 +0900
committerseungha.son <seungha.son@samsung.com>2016-09-07 16:20:23 +0900
commit30bca51d02c3a10994747a77a7686c90e4bb0a2a (patch)
tree1ed38217b58b7ed69a42e233edf7c90bff81ffe0 /src/notification_noti.c
parent59019b59aabc10fec02122523cddd276f38d169d (diff)
downloadnotification-30bca51d02c3a10994747a77a7686c90e4bb0a2a.tar.gz
notification-30bca51d02c3a10994747a77a7686c90e4bb0a2a.tar.bz2
notification-30bca51d02c3a10994747a77a7686c90e4bb0a2a.zip
Add API for get/set notification ongoing value type and time
- Add notification ongoing value type for display time infomation. User gets/sets notification ongoing value type and time. Signed-off-by: seungha.son <seungha.son@samsung.com> Change-Id: Id12bf068c9a11815a7f4f6e94dd383755e073b2e
Diffstat (limited to 'src/notification_noti.c')
-rwxr-xr-xsrc/notification_noti.c21
1 files changed, 16 insertions, 5 deletions
diff --git a/src/notification_noti.c b/src/notification_noti.c
index 1443822..7fa4d19 100755
--- a/src/notification_noti.c
+++ b/src/notification_noti.c
@@ -261,7 +261,9 @@ static int _insertion_query_create(notification_h noti, char **query)
"b_event_handler_click_on_icon, b_event_handler_click_on_thumbnail, "
"sound_type, sound_path, vibration_type, vibration_path, led_operation, led_argb, led_on_ms, led_off_ms, "
"flags_for_property, flag_simmode, display_applist, "
- "progress_size, progress_percentage, ongoing_flag, auto_remove, default_button_index, uid) values ("
+ "progress_size, progress_percentage, "
+ "ongoing_flag, ongoing_value_type, ongoing_current, ongoing_duration, "
+ "auto_remove, default_button_index, uid) values ("
"%d, "
"%d, "
"'%s', '%s', "
@@ -279,7 +281,8 @@ static int _insertion_query_create(notification_h noti, char **query)
"'%s', '%s', "
"%d, '%s', %d, '%s', %d, %d, %d, %d,"
"%d, %d, %d, "
- "$progress_size, $progress_percentage, %d, %d, %d, %d)",
+ "$progress_size, $progress_percentage, "
+ "%d, %d, %d, %d, %d, %d, %d)",
noti->type,
noti->layout,
NOTIFICATION_CHECK_STR(noti->caller_pkgname),
@@ -313,6 +316,9 @@ static int _insertion_query_create(notification_h noti, char **query)
noti->led_off_ms,
noti->flags_for_property, flag_simmode, noti->display_applist,
noti->ongoing_flag,
+ noti->ongoing_value_type,
+ noti->ongoing_current,
+ noti->ongoing_duration,
noti->auto_remove,
noti->default_button_index,
noti->uid);
@@ -451,7 +457,8 @@ static int _update_query_create(notification_h noti, char **query)
"flags_for_property = %d, flag_simmode = %d, "
"display_applist = %d, "
"progress_size = $progress_size, progress_percentage = $progress_percentage, "
- "ongoing_flag = %d, auto_remove = %d, default_button_index = %d "
+ "ongoing_flag = %d, ongoing_value_type = %d, ongoing_current = %d, ongoing_duration = %d, "
+ "auto_remove = %d, default_button_index = %d "
"where priv_id = %d ",
noti->type,
noti->layout,
@@ -483,8 +490,9 @@ static int _update_query_create(notification_h noti, char **query)
noti->led_on_ms,
noti->led_off_ms,
noti->flags_for_property, flag_simmode, noti->display_applist,
- noti->ongoing_flag, noti->auto_remove, noti->default_button_index,
- noti->priv_id);
+ noti->ongoing_flag, noti->ongoing_value_type,
+ noti->ongoing_current, noti->ongoing_duration,
+ noti->auto_remove, noti->default_button_index, noti->priv_id);
/* Free decoded data */
if (args)
@@ -579,6 +587,9 @@ static void _notification_noti_populate_from_stmt(sqlite3_stmt *stmt, notificati
noti->progress_percentage = sqlite3_column_double(stmt, col++);
noti->ongoing_flag = sqlite3_column_int(stmt, col++);
+ noti->ongoing_value_type = sqlite3_column_int(stmt, col++);
+ noti->ongoing_current = sqlite3_column_int(stmt, col++);
+ noti->ongoing_duration = sqlite3_column_int(stmt, col++);
noti->auto_remove = sqlite3_column_int(stmt, col++);
noti->default_button_index = sqlite3_column_int(stmt, col++);