Adjust coding rules 99/63799/5 accepted/tizen/common/20160406.143402 accepted/tizen/ivi/20160406.012024 accepted/tizen/mobile/20160406.011851 accepted/tizen/tv/20160406.011943 accepted/tizen/wearable/20160406.012004 submit/tizen/20160405.001024
authorHwankyu Jhun <h.jhun@samsung.com>
Tue, 29 Mar 2016 01:12:52 +0000 (10:12 +0900)
committerMyungki Lee <mk5004.lee@samsung.com>
Mon, 4 Apr 2016 01:55:28 +0000 (10:55 +0900)
Change-Id: Ia98ac4748d523bd190a0689fccb132d8ea3f7091
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
Signed-off-by: Myungki Lee <mk5004.lee@samsung.com>
35 files changed:
doc/notification_doc.h
include/notification.h
include/notification_db.h
include/notification_debug.h
include/notification_error.h
include/notification_group.h
include/notification_internal.h
include/notification_ipc.h
include/notification_list.h
include/notification_noti.h
include/notification_ongoing.h
include/notification_ongoing_flag.h
include/notification_permission.h
include/notification_private.h
include/notification_setting.h
include/notification_setting_internal.h
include/notification_setting_service.h
include/notification_status.h
include/notification_status_internal.h
include/notification_text_domain.h
include/notification_type.h
src/notification.c
src/notification_db.c
src/notification_error.c
src/notification_group.c
src/notification_internal.c
src/notification_ipc.c
src/notification_list.c
src/notification_noti.c
src/notification_ongoing.c
src/notification_permission.c
src/notification_setting.c
src/notification_setting_service.c
src/notification_status.c
test-app/main.c

index 2dac2af..c397326 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 /**
@@ -33,8 +28,8 @@
  * This API provides functions for creating and inserting and updating notification.
  *
  */
-/** 
+
+/**
  * @internal
  * @defgroup NOTIFICATION_LIST Notification List
  * @ingroup NOTIFICATION_MODULE
@@ -46,8 +41,8 @@
  * It provides functions for handling notification list.
  *
  */
-  
-/** 
+
+/**
  * @defgroup NOTIFICATION_STATUS Notification Status
  * @ingroup NOTIFICATION_MODULE
  * @brief APIs displaying plain text message on the indicator area
@@ -58,4 +53,3 @@
  * Notification status APIs
  *
  */
index e186d47..fd29c85 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_H__
@@ -78,9 +73,8 @@ extern "C" {
 }
  * @endcode
  */
-int notification_set_image(notification_h noti,
-                                           notification_image_type_e type,
-                                           const char *image_path);
+int notification_set_image(notification_h noti, notification_image_type_e type,
+               const char *image_path);
 
 /**
  * @brief Gets the absolute path of an image file.
@@ -100,19 +94,18 @@ int notification_set_image(notification_h noti,
  #include <notification.h>
  ...
  {
-       char *image_path = NULL;
-       int noti_err = NOTIFICATION_ERROR_NONE;
-       
-       noti_err  = notification_get_image(noti, NOTIFICATION_IMAGE_TYPE_ICON, &image_path);
-       if(noti_err != NOTIFICATION_ERROR_NONE) {
+       char *image_path = NULL;
+       int noti_err = NOTIFICATION_ERROR_NONE;
+
+       noti_err  = notification_get_image(noti, NOTIFICATION_IMAGE_TYPE_ICON, &image_path);
+       if (noti_err != NOTIFICATION_ERROR_NONE) {
                return;
-       }
-}
+       }
+ }
  * @endcode
  */
-int notification_get_image(notification_h noti,
-                                           notification_image_type_e type,
-                                           char **image_path);
+int notification_get_image(notification_h noti, notification_image_type_e type,
+               char **image_path);
 
 /**
  * @brief Sets a timestamp.
@@ -134,22 +127,21 @@ int notification_get_image(notification_h noti,
   {
         notification_h noti = NULL;
         int noti_err = NOTIFICATION_ERROR_NONE;
-        
+
         noti = notification_create(NOTIFICATION_TYPE_NOTI);
-        if(noti == NULL) {
+        if (noti == NULL) {
                 return;
         }
+
         noti_err  = notification_set_time(noti, time(NULL));
-        if(noti_err != NOTIFICATION_ERROR_NONE) {
-               notification_free(noti);
-                return;
+        if (noti_err != NOTIFICATION_ERROR_NONE) {
+               notification_free(noti);
+               return;
         }
  }
  * @endcode
  */
-int notification_set_time(notification_h noti,
-                                          time_t input_time);
+int notification_set_time(notification_h noti, time_t input_time);
 
 /**
  * @brief Gets a timestamp.
@@ -169,17 +161,16 @@ int notification_set_time(notification_h noti,
  ...
  {
        time_t ret_time;
-       int noti_err = NOTIFICATION_ERROR_NONE;
-       
-       noti_err  = notification_get_time(noti, &ret_time);
-       if(noti_err != NOTIFICATION_ERROR_NONE) {
+       int noti_err = NOTIFICATION_ERROR_NONE;
+
+       noti_err  = notification_get_time(noti, &ret_time);
+       if (noti_err != NOTIFICATION_ERROR_NONE) {
                return;
-       }
-}
+       }
+ }
  * @endcode
  */
-int notification_get_time(notification_h noti,
-                                          time_t * ret_time);
+int notification_get_time(notification_h noti, time_t *ret_time);
 
 /**
  * @brief Gets an insertion timestamp of the notification.
@@ -196,18 +187,17 @@ int notification_get_time(notification_h noti,
  #include <notification.h>
   ...
   {
-        time_t ret_time;
-        int noti_err = NOTIFICATION_ERROR_NONE;
-        
-        noti_err  = notification_get_insert_time(noti, &ret_time);
-        if(noti_err != NOTIFICATION_ERROR_NONE) {
-                return;
-        }
+       time_t ret_time;
+       int noti_err = NOTIFICATION_ERROR_NONE;
+
+       noti_err  = notification_get_insert_time(noti, &ret_time);
+       if(noti_err != NOTIFICATION_ERROR_NONE) {
+               return;
+       }
  }
  * @endcode
  */
-int notification_get_insert_time(notification_h noti,
-                                                 time_t * ret_time);
+int notification_get_insert_time(notification_h noti, time_t *ret_time);
 
 /**
  * @brief Sets the text to display on the notification view.
@@ -252,11 +242,8 @@ int notification_get_insert_time(notification_h noti,
 }
  * @endcode
  */
-int notification_set_text(notification_h noti,
-                                          notification_text_type_e type,
-                                          const char *text,
-                                          const char *key,
-                                          int args_type, ...);
+int notification_set_text(notification_h noti, notification_text_type_e type,
+               const char *text, const char *key, int args_type, ...);
 
 /**
  * @brief Gets the text from the notification handle.
@@ -284,9 +271,8 @@ int notification_set_text(notification_h noti,
 }
  * @endcode
  */
-int notification_get_text(notification_h noti,
-                                          notification_text_type_e type,
-                                          char **text);
+int notification_get_text(notification_h noti, notification_text_type_e type,
+               char **text);
 
 /**
  * @brief Sets the timestamp to display on the notification view.
@@ -301,8 +287,8 @@ int notification_get_text(notification_h noti,
  * @retval #NOTIFICATION_ERROR_INVALID_PARAMETER Invalid parameter
  * @pre Notification handle should be created by notification_create().
  */
-int notification_set_time_to_text(notification_h noti, notification_text_type_e type,
-                                                               time_t time);
+int notification_set_time_to_text(notification_h noti,
+               notification_text_type_e type, time_t time);
 
 /**
  * @brief Gets the timestamp from the notification handle.
@@ -316,8 +302,8 @@ int notification_set_time_to_text(notification_h noti, notification_text_type_e
  * @retval #NOTIFICATION_ERROR_INVALID_PARAMETER Invalid parameter
  * @pre Notification handle should be created by notification_create().
  */
-int notification_get_time_from_text(notification_h noti, notification_text_type_e type,
-                                                               time_t *time);
+int notification_get_time_from_text(notification_h noti,
+               notification_text_type_e type, time_t *time);
 
 /**
  * @brief Sets the sound type for the notification.
@@ -345,8 +331,7 @@ int notification_get_time_from_text(notification_h noti, notification_text_type_
  * @endcode
  */
 int notification_set_sound(notification_h noti,
-                                           notification_sound_type_e type,
-                                           const char *path);
+               notification_sound_type_e type, const char *path);
 
 /**
  * @brief Gets the sound type from the notification handle.
@@ -375,8 +360,7 @@ int notification_set_sound(notification_h noti,
  * @endcode
  */
 int notification_get_sound(notification_h noti,
-                                           notification_sound_type_e *type,
-                                           const char **path);
+               notification_sound_type_e *type, const char **path);
 
 /**
  * @brief Sets the vibration type for the notification.
@@ -404,8 +388,7 @@ int notification_get_sound(notification_h noti,
  * @endcode
  */
 int notification_set_vibration(notification_h noti,
-                                               notification_vibration_type_e type,
-                                               const char *path);
+               notification_vibration_type_e type, const char *path);
 
 /**
  * @brief Gets the vibrate type from the notification handle.
@@ -434,8 +417,7 @@ int notification_set_vibration(notification_h noti,
   * @endcode
   */
 int notification_get_vibration(notification_h noti,
-                                               notification_vibration_type_e *type,
-                                               const char **path);
+               notification_vibration_type_e *type, const char **path);
 
 /**
  * @brief Sets the LED displaying option.
@@ -462,9 +444,8 @@ int notification_get_vibration(notification_h noti,
 }
  * @endcode
  */
-int notification_set_led(notification_h noti,
-                                               notification_led_op_e operation,
-                                               int led_argb);
+int notification_set_led(notification_h noti, notification_led_op_e operation,
+               int led_argb);
 
 /**
  * @brief Gets the LED displaying option from the notification handle.
@@ -492,9 +473,8 @@ int notification_set_led(notification_h noti,
 }
   * @endcode
   */
-int notification_get_led(notification_h noti,
-                                               notification_led_op_e *operation,
-                                               int *led_argb);
+int notification_get_led(notification_h noti, notification_led_op_e *operation,
+               int *led_argb);
 
 /**
  * @brief Sets the time period of flashing the LED.
@@ -521,8 +501,8 @@ int notification_get_led(notification_h noti,
 }
  * @endcode
  */
-int notification_set_led_time_period(notification_h noti,
-                                               int on_ms, int off_ms);
+int notification_set_led_time_period(notification_h noti, int on_ms,
+               int off_ms);
 
 /**
  * @brief Gets the time period of flashing the LED from the notification handle.
@@ -551,8 +531,8 @@ int notification_set_led_time_period(notification_h noti,
 }
   * @endcode
   */
-int notification_get_led_time_period(notification_h noti,
-                                               int *on_ms, int *off_ms);
+int notification_get_led_time_period(notification_h noti, int *on_ms,
+               int *off_ms);
 
 /**
  * @brief Sets the launch option for a notification.
@@ -592,7 +572,7 @@ int notification_get_led_time_period(notification_h noti,
  * @endcode
  */
 int notification_set_launch_option(notification_h noti,
-                                                               notification_launch_option_type type, void *option);
+               notification_launch_option_type type, void *option);
 
 /**
  * @brief Gets the launch option from the notification handle.
@@ -624,7 +604,7 @@ int notification_set_launch_option(notification_h noti,
  * @endcode
  */
 int notification_get_launch_option(notification_h noti,
-                                                               notification_launch_option_type type, void *option);
+               notification_launch_option_type type, void *option);
 
 /**
  * @brief Sets the handler for a specific event.
@@ -665,7 +645,9 @@ int notification_get_launch_option(notification_h noti,
 }
  * @endcode
  */
-int notification_set_event_handler(notification_h noti, notification_event_type_e event_type, app_control_h event_handler);
+int notification_set_event_handler(notification_h noti,
+               notification_event_type_e event_type,
+               app_control_h event_handler);
 
 /**
  * @brief Gets the event handler of a specific event.
@@ -697,7 +679,9 @@ int notification_set_event_handler(notification_h noti, notification_event_type_
 }
  * @endcode
  */
-int notification_get_event_handler(notification_h noti, notification_event_type_e event_type, app_control_h *event_handler);
+int notification_get_event_handler(notification_h noti,
+               notification_event_type_e event_type,
+               app_control_h *event_handler);
 
 /**
  * @brief Sets the property of the notification.
@@ -730,8 +714,7 @@ int notification_get_event_handler(notification_h noti, notification_event_type_
 }
  * @endcode
  */
-int notification_set_property(notification_h noti,
-                                              int flags);
+int notification_set_property(notification_h noti, int flags);
 
 /**
  * @brief Gets the property of the notification from the notification handle.
@@ -758,8 +741,7 @@ int notification_set_property(notification_h noti,
 }
  * @endcode
  */
-int notification_get_property(notification_h noti,
-                                              int *flags);
+int notification_get_property(notification_h noti, int *flags);
 
 /**
  * @brief Sets applications to display the notification.
@@ -794,8 +776,7 @@ int notification_get_property(notification_h noti,
 }
  * @endcode
  */
-int notification_set_display_applist(notification_h noti,
-                                                     int applist);
+int notification_set_display_applist(notification_h noti, int applist);
 
 /**
  * @brief Gets the application list displaying the notification from the notification handle.
@@ -822,8 +803,7 @@ int notification_set_display_applist(notification_h noti,
 }
  * @endcode
  */
-int notification_get_display_applist(notification_h noti,
-                                                     int *applist);
+int notification_get_display_applist(notification_h noti, int *applist);
 
 /**
  * @brief Sets the initial size for the ongoing type.
@@ -856,8 +836,7 @@ int notification_get_display_applist(notification_h noti,
 }
  * @endcode
  */
-int notification_set_size(notification_h noti,
-                                          double size);
+int notification_set_size(notification_h noti, double size);
 
 /**
  * @brief Gets the progress size.
@@ -884,8 +863,7 @@ int notification_set_size(notification_h noti,
 }
  * @endcode
  */
-int notification_get_size(notification_h noti,
-                                          double *size);
+int notification_get_size(notification_h noti, double *size);
 
 /**
  * @brief Sets the initial progress for the ongoing type.
@@ -918,8 +896,7 @@ int notification_get_size(notification_h noti,
 }
  * @endcode
  */
-int notification_set_progress(notification_h noti,
-                                              double percentage);
+int notification_set_progress(notification_h noti, double percentage);
 
 /**
  * @brief Gets the progress from the notification handle.
@@ -947,8 +924,7 @@ int notification_set_progress(notification_h noti,
 }
  * @endcode
  */
-int notification_get_progress(notification_h noti,
-                                              double *percentage);
+int notification_get_progress(notification_h noti, double *percentage);
 
 /**
  * @brief Sets the layout of the notification view.
@@ -962,8 +938,7 @@ int notification_get_progress(notification_h noti,
  * @retval #NOTIFICATION_ERROR_INVALID_PARAMETER Invalid input value
  * @see #notification_ly_type_e
  */
-int notification_set_layout(notification_h noti,
-               notification_ly_type_e layout);
+int notification_set_layout(notification_h noti, notification_ly_type_e layout);
 
 /**
  * @brief Gets the layout of the notification view from the notification handle.
@@ -1003,8 +978,7 @@ int notification_get_layout(notification_h noti,
 }
  * @endcode
  */
-int notification_get_type(notification_h noti,
-                                          notification_type_e * type);
+int notification_get_type(notification_h noti, notification_type_e *type);
 /**
  * @brief Updates notification data.
  * @details The updated notification will appear in the notification area.
@@ -1051,7 +1025,7 @@ int notification_update(notification_h noti);
 #include <notification.h>
 ...
  {
-       notificaton_h noti = NULL;
+       notificaton_h noti = NULL;
        int noti_err = NOTIFICATION_ERROR_NONE;
 
        ...
@@ -1061,7 +1035,7 @@ int notification_update(notification_h noti);
                return;
        }
 
-}
+ }
  * @endcode
  */
 int notification_delete(notification_h noti);
@@ -1374,7 +1348,8 @@ int notification_get_pkgname(notification_h noti, char **pkgname);
 }
  * @endcode
  */
-int notification_add_button(notification_h noti, notification_button_index_e button_index);
+int notification_add_button(notification_h noti,
+               notification_button_index_e button_index);
 
 /**
  * @brief Removes a button on the notification
@@ -1404,7 +1379,8 @@ int notification_add_button(notification_h noti, notification_button_index_e but
 }
  * @endcode
  */
-int notification_remove_button(notification_h noti, notification_button_index_e button_index);
+int notification_remove_button(notification_h noti,
+               notification_button_index_e button_index);
 
 /**
  * @brief Sets the 'auto remove' option of the active notification
@@ -1473,4 +1449,5 @@ int notification_get_auto_remove(notification_h noti, bool *auto_remove);
 #ifdef __cplusplus
 }
 #endif
-#endif                         /* __NOTIFICATION_H__ */
+#endif /* __NOTIFICATION_H__ */
+
index ac631c9..3616a80 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_DB_H__
 #define DBPATH tzplatform_mkpath(TZ_SYS_DB, ".notification.db")
 #define NOTIFICATION_QUERY_MAX 4096
 #define NOTIFICATION_EMPTY_STR ""
-#define NOTIFICATION_CHECK_STR(p) ((p)?(p):NOTIFICATION_EMPTY_STR)
+#define NOTIFICATION_CHECK_STR(p) ((p) ? (p) : NOTIFICATION_EMPTY_STR)
 
 sqlite3 *notification_db_open(const char *dbfile);
-int notification_db_close(sqlite3 ** db);
-int notification_db_exec(sqlite3 * db, const char *query, int *num_changes);
-char *notification_db_column_text(sqlite3_stmt * stmt, int col);
-bundle *notification_db_column_bundle(sqlite3_stmt * stmt, int col);
+int notification_db_close(sqlite3 **db);
+int notification_db_exec(sqlite3 *db, const char *query, int *num_changes);
+char *notification_db_column_text(sqlite3_stmt *stmt, int col);
+bundle *notification_db_column_bundle(sqlite3_stmt *stmt, int col);
+
+#endif /* __NOTIFICATION_DB_H__ */
 
-#endif                         /* __NOTIFICATION_DB_H__ */
index e507471..29e38fc 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_DEBUG_H__
 #include <stdio.h>
 
 #define NOTIFICATION_DBG(fmt , args...) \
-       do{ \
-               printf("[D][%s : %d] "fmt"\n", __func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               printf("[D][%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_INFO(fmt , args...) \
-       do{ \
-               printf("[I][%s : %d] "fmt"\n", __func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               printf("[I][%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_WARN(fmt , args...) \
-       do{ \
-               printf("[W][%s : %d] "fmt"\n", __func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               printf("[W][%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_ERR(fmt , args...) \
-       do{ \
-               printf("[E][%s : %d] "fmt"\n", __func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               printf("[E][%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #else /* _DLOG_H_ */
 
 #define NOTIFICATION_DBG(fmt , args...) \
-       do{ \
-               SECURE_LOGD("[%s : %d] "fmt"\n",__func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               SECURE_LOGD("[%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_INFO(fmt , args...) \
-       do{ \
-               SECURE_LOGI("[%s : %d] "fmt"\n",__func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               SECURE_LOGI("[%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_WARN(fmt , args...) \
-       do{ \
-               SECURE_LOGW("[%s : %d] "fmt"\n",__func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               SECURE_LOGW("[%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #define NOTIFICATION_ERR(fmt , args...) \
-       do{ \
-               SECURE_LOGE("[%s : %d] "fmt"\n",__func__,__LINE__,##args ); \
-       } while(0)
+       do { \
+               SECURE_LOGE("[%s : %d] "fmt"\n", __func__, __LINE__, ##args); \
+       } while (0)
 
 #endif /* _DLOG_H_ */
 
-#endif                         /* __NOTIFICATION_DEBUG_H__ */
+#endif /* __NOTIFICATION_DEBUG_H__ */
+
index 87b4e33..317ef18 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_ERROR_H__
@@ -41,7 +36,7 @@ typedef enum _notification_error {
        NOTIFICATION_ERROR_NONE = TIZEN_ERROR_NONE,     /**< Success */
        NOTIFICATION_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER,   /**< Invalid parameter */
        NOTIFICATION_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY,   /**< out of memory */
-       NOTIFICATION_ERROR_IO_ERROR= TIZEN_ERROR_IO_ERROR,      /**< I/O error */
+       NOTIFICATION_ERROR_IO_ERROR = TIZEN_ERROR_IO_ERROR,     /**< I/O error */
        NOTIFICATION_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< Permission denied */
        NOTIFICATION_ERROR_FROM_DB = TIZEN_ERROR_NOTIFICATION | 0x01,   /**< Error from DB query */
        NOTIFICATION_ERROR_ALREADY_EXIST_ID = TIZEN_ERROR_NOTIFICATION | 0x02,  /**< Already exist private ID */
@@ -55,4 +50,5 @@ typedef enum _notification_error {
  * @}
  */
 
-#endif                         /* __NOTIFICATION_ERROR_H__ */
+#endif /* __NOTIFICATION_ERROR_H__ */
+
index 2bff013..f6affa8 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_GROUP_H__
 
 #include <notification.h>
 
-NOTIFICATION_DEPRECATED_API int notification_group_set_title(const char *pkgname,
-                                                 int group_id,
-                                                 const char *title,
-                                                 const char *loc_title,
-                                                 notification_count_display_type_e count_display);
-
-NOTIFICATION_DEPRECATED_API int notification_group_get_title(const char *pkgname,
-                                                 int group_id,
-                                                 char **ret_title,
-                                                 char **ret_loc_title,
-                                                 notification_count_display_type_e *count_display);
-
-NOTIFICATION_DEPRECATED_API int notification_group_set_content(const char *pkgname,
-                                                   int group_id,
-                                                   const char *content,
-                                                   const char *loc_content,
-                                                   notification_count_display_type_e count_display);
-
-NOTIFICATION_DEPRECATED_API int notification_group_get_content(const char *pkgname,
-                                                   int group_id,
-                                                   char **ret_content,
-                                                   char **ret_loc_content,
-                                                   notification_count_display_type_e *count_display);
-
-NOTIFICATION_DEPRECATED_API int notification_group_set_badge(const char *pkgname,
-                                                 int group_id, int count);
-
-NOTIFICATION_DEPRECATED_API int notification_group_get_badge(const char *pkgname,
-                                                 int group_id, int *count);
-
-#endif                         /* __NOTIFICATION_GROUP_H__ */
+NOTIFICATION_DEPRECATED_API int notification_group_set_title(
+               const char *pkgname, int group_id, const char *title,
+               const char *loc_title,
+               notification_count_display_type_e count_display);
+
+NOTIFICATION_DEPRECATED_API int notification_group_get_title(
+               const char *pkgname, int group_id, char **ret_title,
+               char **ret_loc_title,
+               notification_count_display_type_e *count_display);
+
+NOTIFICATION_DEPRECATED_API int notification_group_set_content(
+               const char *pkgname, int group_id, const char *content,
+               const char *loc_content,
+               notification_count_display_type_e count_display);
+
+NOTIFICATION_DEPRECATED_API int notification_group_get_content(
+               const char *pkgname, int group_id, char **ret_content,
+               char **ret_loc_content,
+               notification_count_display_type_e *count_display);
+
+NOTIFICATION_DEPRECATED_API int notification_group_set_badge(
+               const char *pkgname, int group_id, int count);
+
+NOTIFICATION_DEPRECATED_API int notification_group_get_badge(
+               const char *pkgname, int group_id, int *count);
+
+#endif /* __NOTIFICATION_GROUP_H__ */
+
index c30e5ac..c63f8b7 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_INTERNAL_H__
@@ -36,7 +31,7 @@ extern "C" {
  */
 
 #define NOTIFICATION_DISPLAY_APP_HEADS_UP NOTIFICATION_DISPLAY_APP_ACTIVE /* To avoid build error */
-#define NOTIFICATION_ERROR (notification_error_quark ())
+#define NOTIFICATION_ERROR (notification_error_quark())
 GQuark notification_error_quark(void);
 
 /**
@@ -228,14 +223,14 @@ NOTIFICATION_DEPRECATED_API int notification_get_application(notification_h noti
  * @see notification_set_execute_option()
  *
  */
-NOTIFICATION_DEPRECATED_API int notification_set_args(notification_h noti, bundle * args, bundle * group_args);        /* Do not use this */
+NOTIFICATION_DEPRECATED_API int notification_set_args(notification_h noti, bundle *args, bundle *group_args);  /* Do not use this */
 
 /**
  * @brief This function will be deprecated.
  * @see notification_get_execute_option()
  *
  */
-NOTIFICATION_DEPRECATED_API int notification_get_args(notification_h noti, bundle ** args, bundle ** group_args);      /* Do not use this */
+NOTIFICATION_DEPRECATED_API int notification_get_args(notification_h noti, bundle **args, bundle **group_args);        /* Do not use this */
 
 /**
  * @brief This function is deprecated.
@@ -471,7 +466,7 @@ NOTIFICATION_DEPRECATED_API int notification_set_execute_option(notification_h n
   {
         int noti_err = NOTIFICATION_ERROR_NONE;
         int group_id, priv_id;
+
         noti_err  = notification_get_id(noti, &group_id, &priv_id);
         if(noti_err != NOTIFICATION_ERROR_NONE) {
                 return;
@@ -716,3 +711,4 @@ int notification_unregister_detailed_changed_cb(
 }
 #endif
 #endif
+
index 2c91e0f..fc31c04 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_IPC_H__
@@ -33,44 +28,62 @@ extern "C" {
 #endif
 
 GVariant *notification_ipc_make_gvariant_from_noti(notification_h noti);
-int notification_ipc_make_noti_from_gvariant(notification_h noti, GVariant *variant);
+int notification_ipc_make_noti_from_gvariant(notification_h noti,
+               GVariant *variant);
 
-GVariant *notification_ipc_make_gvariant_from_setting(struct notification_setting *noti_setting);
-int notification_ipc_make_setting_from_gvariant(struct notification_setting *noti_setting,
-                               GVariant *variant);
+GVariant *notification_ipc_make_gvariant_from_setting(
+               struct notification_setting *noti_setting);
+int notification_ipc_make_setting_from_gvariant(
+               struct notification_setting *noti_setting, GVariant *variant);
 
-GVariant *notification_ipc_make_gvariant_from_system_setting(struct notification_system_setting *noti_setting);
-int notification_ipc_make_system_setting_from_gvariant(struct notification_system_setting *noti_setting,
-                               GVariant *variant);
+GVariant *notification_ipc_make_gvariant_from_system_setting(
+               struct notification_system_setting *noti_setting);
+int notification_ipc_make_system_setting_from_gvariant(
+               struct notification_system_setting *noti_setting,
+               GVariant *variant);
 
 int notification_dbus_init();
 int notification_ipc_monitor_init(void);
 int notification_ipc_monitor_fini(void);
 
 int notification_ipc_is_master_ready(void);
-int notification_ipc_add_deffered_task(void (*deferred_task_cb)(void *data), void *user_data);
+int notification_ipc_add_deffered_task(void (*deferred_task_cb)(void *data),
+               void *user_data);
 int notification_ipc_del_deffered_task(void (*deferred_task_cb)(void *data));
 int notification_ipc_request_insert(notification_h noti, int *priv_id);
 int notification_ipc_request_update(notification_h noti);
 int notification_ipc_request_update_async(notification_h noti,
-               void (*result_cb)(int priv_id, int result, void *data), void *user_data);
+               void (*result_cb)(int priv_id, int result, void *data),
+               void *user_data);
 int notification_ipc_request_refresh(void);
-int notification_ipc_request_delete_multiple(notification_type_e type, char *pkgname);
-int notification_ipc_request_delete_single(notification_type_e type, char *pkgname, int priv_id);
+int notification_ipc_request_delete_multiple(notification_type_e type,
+               char *pkgname);
+int notification_ipc_request_delete_single(notification_type_e type,
+               char *pkgname, int priv_id);
 int notification_ipc_update_setting(notification_setting_h setting);
-int notification_ipc_update_system_setting(notification_system_setting_h system_setting);
-int notification_ipc_request_load_noti_by_tag(notification_h noti, const char *pkgname, const char *tag);
-int notification_ipc_request_load_noti_grouping_list(notification_type_e type, int count,
+int notification_ipc_update_system_setting(
+               notification_system_setting_h system_setting);
+int notification_ipc_request_load_noti_by_tag(notification_h noti,
+               const char *pkgname, const char *tag);
+int notification_ipc_request_load_noti_grouping_list(notification_type_e type,
+               int count,
                notification_list_h *list);
-int notification_ipc_request_get_setting_array(notification_setting_h *setting_array, int *count);
+int notification_ipc_request_get_setting_array(
+               notification_setting_h *setting_array, int *count);
 int notification_ipc_request_get_setting_by_package_name(
-                               const char *package_name, notification_setting_h *setting);
-int notification_ipc_request_load_system_setting(notification_system_setting_h *setting);
-int notification_ipc_request_get_count(notification_type_e type, const char *pkgname, int group_id, int priv_id, int *count);
-int notification_ipc_request_load_noti_by_priv_id(notification_h noti, const char *pkgname, int priv_id);
-int notification_ipc_request_load_noti_detail_list(const char *pkgname, int group_id, int priv_id, int count, notification_list_h *list);
+               const char *package_name, notification_setting_h *setting);
+int notification_ipc_request_load_system_setting(
+               notification_system_setting_h *setting);
+int notification_ipc_request_get_count(notification_type_e type,
+               const char *pkgname, int group_id, int priv_id, int *count);
+int notification_ipc_request_load_noti_by_priv_id(notification_h noti,
+               const char *pkgname, int priv_id);
+int notification_ipc_request_load_noti_detail_list(const char *pkgname,
+               int group_id, int priv_id, int count,
+               notification_list_h *list);
 
 #ifdef __cplusplus
 }
 #endif
-#endif
+#endif /* __NOTIFICATION_IPC_H__ */
+
index ce77189..6741a66 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_LIST_H__
@@ -78,7 +73,7 @@ typedef struct _notification_list *notification_list_h;
  */
 int notification_get_list(notification_type_e type,
                                           int count,
-                                          notification_list_h * list);
+                                          notification_list_h *list);
 
 /**
  * @brief Returns the notification detail list handle of grouping data.
@@ -360,9 +355,9 @@ notification_list_h notification_list_append(notification_list_h list,
        notification_h noti = NULL;
        notification_list_h noti_list = NULL;
        int noti_err = NOTIFICATION_ERROR_NONE;
-       
+
        ...
-       
+
        noti_list = notification_list_remove(noti_list, noti);
 }
  * @endcode
@@ -370,11 +365,12 @@ notification_list_h notification_list_append(notification_list_h list,
 notification_list_h notification_list_remove(notification_list_h list,
                                             notification_h noti);
 
-/** 
+/**
  * @}
  */
 
 #ifdef __cplusplus
 }
 #endif
-#endif                         /* __NOTIFICATION_LIST_H__ */
+#endif /* __NOTIFICATION_LIST_H__ */
+
index 0d04c0b..bb774e0 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_NOTI_H__
@@ -68,4 +63,5 @@ int notification_noti_get_detail_list(const char *pkgname,
 
 int notification_noti_check_tag(notification_h noti);
 
-#endif                         /* __NOTIFICATION_NOTI_H__ */
+#endif /* __NOTIFICATION_NOTI_H__ */
+
index 5fb4141..0d60ab6 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_ONGOING_H__
@@ -33,4 +28,5 @@ int notification_ongoing_update_size(const char *caller_pkgname,
 int notification_ongoing_update_content(const char *caller_pkgname,
                                                      int priv_id, const char *content);
 
-#endif                         /* __NOTIFICATION_ONGOING_H__ */
+#endif /* __NOTIFICATION_ONGOING_H__ */
+
index 0777bf5..cb8c149 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyuho Jo <kyuho.jo@samsung.com>
+ * Copyright (c) 2015 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_ONGOING_FLAG_H__
@@ -84,4 +79,5 @@ int notification_set_ongoing_flag(notification_h noti, bool ongoing_flag);
  */
 int notification_get_ongoing_flag(notification_h noti, bool *ongoing_flag);
 
-#endif                         /* __NOTIFICATION_ONGOING_H__ */
+#endif /* __NOTIFICATION_ONGOING_H__ */
+
index 9e82601..da92a58 100644 (file)
@@ -1,6 +1,4 @@
 /*
- *  libnotification
- *
  * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
@@ -14,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_PERMISSION_H__
@@ -26,4 +23,5 @@
 
 int notification_check_permission();
 
-#endif                         /* __NOTIFICATION_PERMISSION_H__ */
+#endif /* __NOTIFICATION_PERMISSION_H__ */
+
index 1e98d38..2d292ea 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_PRIVATE_H__
 #define EXPORT_API __attribute__ ((visibility("default")))
 #endif
 
-#define SAFE_STRDUP(s) \
-               ({\
-       char* _s = (char*)s;\
-       (_s)? strdup(_s) : NULL;\
-})
-
-#define SAFE_FREE(s) \
-               ({\
-       if (s) {\
-               free(s);\
-               s = NULL;\
-       }\
-})
+#define SAFE_STRDUP(s) ((s) ? strdup(s) : NULL)
+#define SAFE_FREE(s)                   \
+       do {                            \
+               if (s) {                \
+                       free(s);        \
+                       s = NULL;       \
+               }                       \
+       } while (0)
 
 #define NOTIFICATION_SETTING_DB_TABLE "notification_setting"
 #define NOTIFICATION_SYSTEM_SETTING_DB_TABLE "notification_system_setting"
@@ -106,59 +96,60 @@ struct notification_system_setting {
 };
 
 typedef enum notification_data_type {
-    NOTIFICATION_DATA_TYPE_NOTI_TYPE = 1,
-    NOTIFICATION_DATA_TYPE_LAYOUT,
-    NOTIFICATION_DATA_TYPE_GROUP_ID,
-    NOTIFICATION_DATA_TYPE_INTERNAL_GROUP_ID,
-    NOTIFICATION_DATA_TYPE_PRIV_ID,
-    NOTIFICATION_DATA_TYPE_CALLER_PKGNAME,
-    NOTIFICATION_DATA_TYPE_LAUNCH_PKGNAME,
-    NOTIFICATION_DATA_TYPE_ARGS,
-    NOTIFICATION_DATA_TYPE_GROUP_ARGS,
-    NOTIFICATION_DATA_TYPE_EXECUTE_OPTION,
-    NOTIFICATION_DATA_TYPE_SERVICE_RESPONDING,
-    NOTIFICATION_DATA_TYPE_SERVICE_SINGLE_LAUNCH,
-    NOTIFICATION_DATA_TYPE_SERVICE_MULTI_LAUNCH,
-    NOTIFICATION_DATA_TYPE_BUTTON1_EVENT,
-    NOTIFICATION_DATA_TYPE_BUTTON2_EVENT,
-    NOTIFICATION_DATA_TYPE_BUTTON3_EVENT,
-    NOTIFICATION_DATA_TYPE_BUTTON4_EVENT,
-    NOTIFICATION_DATA_TYPE_BUTTON5_EVENT,
-    NOTIFICATION_DATA_TYPE_BUTTON6_EVENT,
-    NOTIFICATION_DATA_TYPE_ICON_EVENT,
-    NOTIFICATION_DATA_TYPE_THUMBNAIL_EVENT,
-    NOTIFICATION_DATA_TYPE_DOMAIN,
-    NOTIFICATION_DATA_TYPE_DIR,
-    NOTIFICATION_DATA_TYPE_TEXT,
-    NOTIFICATION_DATA_TYPE_KEY,
-    NOTIFICATION_DATA_TYPE_FORMAT_ARGS,
-    NOTIFICATION_DATA_TYPE_NUM_FORMAT_ARGS,
-    NOTIFICATION_DATA_TYPE_IMAGE_PATH,
-    NOTIFICATION_DATA_TYPE_SOUND_TYPE,
-    NOTIFICATION_DATA_TYPE_SOUND_PATH,
-    NOTIFICATION_DATA_TYPE_VIBRATION_TYPE,
-    NOTIFICATION_DATA_TYPE_VIBRATION_PATH,
-    NOTIFICATION_DATA_TYPE_LED_OPERATION,
-    NOTIFICATION_DATA_TYPE_LED_ARGB,
-    NOTIFICATION_DATA_TYPE_LED_ON_MS,
-    NOTIFICATION_DATA_TYPE_LED_OFF_MS,
-    NOTIFICATION_DATA_TYPE_TIME,
-    NOTIFICATION_DATA_TYPE_INSERT_TIME,
-    NOTIFICATION_DATA_TYPE_FLAGS_FOR_PROPERTY,
-    NOTIFICATION_DATA_TYPE_DISPLAY_APPLIST,
-    NOTIFICATION_DATA_TYPE_PROGRESS_SIZE,
-    NOTIFICATION_DATA_TYPE_PROGRESS_PERCENTAGE,
-    NOTIFICATION_DATA_TYPE_APP_ICON_PATH,
-    NOTIFICATION_DATA_TYPE_APP_NAME,
-    NOTIFICATION_DATA_TYPE_TEMP_TITLE,
-    NOTIFICATION_DATA_TYPE_TEMP_CONTENT,
-    NOTIFICATION_DATA_TYPE_TAG,
-    NOTIFICATION_DATA_TYPE_ONGOING_FLAG,
-    NOTIFICATION_DATA_TYPE_AUTO_REMOVE,
+       NOTIFICATION_DATA_TYPE_NOTI_TYPE = 1,
+       NOTIFICATION_DATA_TYPE_LAYOUT,
+       NOTIFICATION_DATA_TYPE_GROUP_ID,
+       NOTIFICATION_DATA_TYPE_INTERNAL_GROUP_ID,
+       NOTIFICATION_DATA_TYPE_PRIV_ID,
+       NOTIFICATION_DATA_TYPE_CALLER_PKGNAME,
+       NOTIFICATION_DATA_TYPE_LAUNCH_PKGNAME,
+       NOTIFICATION_DATA_TYPE_ARGS,
+       NOTIFICATION_DATA_TYPE_GROUP_ARGS,
+       NOTIFICATION_DATA_TYPE_EXECUTE_OPTION,
+       NOTIFICATION_DATA_TYPE_SERVICE_RESPONDING,
+       NOTIFICATION_DATA_TYPE_SERVICE_SINGLE_LAUNCH,
+       NOTIFICATION_DATA_TYPE_SERVICE_MULTI_LAUNCH,
+       NOTIFICATION_DATA_TYPE_BUTTON1_EVENT,
+       NOTIFICATION_DATA_TYPE_BUTTON2_EVENT,
+       NOTIFICATION_DATA_TYPE_BUTTON3_EVENT,
+       NOTIFICATION_DATA_TYPE_BUTTON4_EVENT,
+       NOTIFICATION_DATA_TYPE_BUTTON5_EVENT,
+       NOTIFICATION_DATA_TYPE_BUTTON6_EVENT,
+       NOTIFICATION_DATA_TYPE_ICON_EVENT,
+       NOTIFICATION_DATA_TYPE_THUMBNAIL_EVENT,
+       NOTIFICATION_DATA_TYPE_DOMAIN,
+       NOTIFICATION_DATA_TYPE_DIR,
+       NOTIFICATION_DATA_TYPE_TEXT,
+       NOTIFICATION_DATA_TYPE_KEY,
+       NOTIFICATION_DATA_TYPE_FORMAT_ARGS,
+       NOTIFICATION_DATA_TYPE_NUM_FORMAT_ARGS,
+       NOTIFICATION_DATA_TYPE_IMAGE_PATH,
+       NOTIFICATION_DATA_TYPE_SOUND_TYPE,
+       NOTIFICATION_DATA_TYPE_SOUND_PATH,
+       NOTIFICATION_DATA_TYPE_VIBRATION_TYPE,
+       NOTIFICATION_DATA_TYPE_VIBRATION_PATH,
+       NOTIFICATION_DATA_TYPE_LED_OPERATION,
+       NOTIFICATION_DATA_TYPE_LED_ARGB,
+       NOTIFICATION_DATA_TYPE_LED_ON_MS,
+       NOTIFICATION_DATA_TYPE_LED_OFF_MS,
+       NOTIFICATION_DATA_TYPE_TIME,
+       NOTIFICATION_DATA_TYPE_INSERT_TIME,
+       NOTIFICATION_DATA_TYPE_FLAGS_FOR_PROPERTY,
+       NOTIFICATION_DATA_TYPE_DISPLAY_APPLIST,
+       NOTIFICATION_DATA_TYPE_PROGRESS_SIZE,
+       NOTIFICATION_DATA_TYPE_PROGRESS_PERCENTAGE,
+       NOTIFICATION_DATA_TYPE_APP_ICON_PATH,
+       NOTIFICATION_DATA_TYPE_APP_NAME,
+       NOTIFICATION_DATA_TYPE_TEMP_TITLE,
+       NOTIFICATION_DATA_TYPE_TEMP_CONTENT,
+       NOTIFICATION_DATA_TYPE_TAG,
+       NOTIFICATION_DATA_TYPE_ONGOING_FLAG,
+       NOTIFICATION_DATA_TYPE_AUTO_REMOVE,
 } notification_data_type_e;
 
 void notification_call_changed_cb(notification_op *op_list, int op_num);
 
 char *notification_get_pkgname_by_pid(void);
 
-#endif                         /* __NOTIFICATION_PRIVATE_H__ */
+#endif /* __NOTIFICATION_PRIVATE_H__ */
+
index 39a5ec5..7c19c38 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_SETTING_H__
@@ -29,7 +24,7 @@
 extern "C" {
 #endif
 
-typedef struct notification_settingnotification_setting_h;
+typedef struct notification_setting *notification_setting_h;
 
 int notification_setting_get_setting(notification_setting_h *setting);
 
@@ -45,4 +40,5 @@ int notification_setting_refresh_setting_table();
 #ifdef __cplusplus
 }
 #endif
-#endif                         /* __NOTIFICATION_SETTING_H__ */
+#endif /* __NOTIFICATION_SETTING_H__ */
+
index 83bcf75..f8c70a3 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyho Jo <kyuho.jo@samsung.com>
+ * Copyright (c) 2015 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_SETTING_INTERNAL_H__
@@ -54,7 +49,7 @@ int notification_setting_insert_package(const char *package_id);
 int notification_setting_delete_package(const char *package_id);
 
 /* System setting */
-typedef struct notification_system_settingnotification_system_setting_h;
+typedef struct notification_system_setting *notification_system_setting_h;
 
 int notification_system_setting_load_system_setting(notification_system_setting_h *system_setting);
 int notification_system_setting_update_system_setting(notification_system_setting_h system_setting);
@@ -74,3 +69,4 @@ int notification_setting_property_get(const char *pkgname, const char *property,
 }
 #endif
 #endif /* __NOTIFICATION_SETTING_INTERNAL_H__ */
+
index 63f37c4..7b3a52c 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_SETTING_SERVICE_H__
@@ -41,4 +36,5 @@ int noti_system_setting_load_system_setting(notification_system_setting_h *syste
 #ifdef __cplusplus
 }
 #endif
-#endif                         /* __NOTIFICATION_SETTING_SERVICE_H__ */
+#endif /* __NOTIFICATION_SETTING_SERVICE_H__ */
+
index ccfd07c..cdcdfbc 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_STATUS_DEF_H__
@@ -55,3 +50,4 @@ int notification_status_message_post(const char *message);
 }
 #endif /* __cplusplus */
 #endif /* __NOTIFICATION_STATUS_DEF_H__ */
+
index 0e10851..fcfb94e 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_STATUS_INTERNAL_DEF_H__
@@ -107,3 +102,4 @@ int notification_status_monitor_message_cb_unset(void);
 }
 #endif /* __cplusplus */
 #endif /* __NOTIFICATION_STATUS_INTERNAL_DEF_H__ */
+
index e7bd4e2..9902719 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyuho Jo <kyuho.jo@samsung.com>
+ * Copyright (c) 2015 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_TEXT_DOMAIN_H__
@@ -97,3 +92,4 @@ int notification_get_text_domain(notification_h noti,
 }
 #endif /* __cplusplus */
 #endif /* __NOTIFICATION_TEXT_DOMAIN_H__ */
+
index f2f9ea0..c7d22dc 100644 (file)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #ifndef __NOTIFICATION_TYPE_H__
@@ -27,7 +22,7 @@ extern "C" {
 #endif
 
 #ifndef NOTIFICATION_DEPRECATED_API
-#if 0//__GNUC__
+#if 0 /* __GNUC__ */
 #define NOTIFICATION_DEPRECATED_API __attribute__((deprecated))
 #else
 #define NOTIFICATION_DEPRECATED_API
@@ -52,20 +47,20 @@ extern "C" {
  */
 typedef enum _notification_ly_type {
        NOTIFICATION_LY_NONE = 0,
-               /**< Default */
+       /**< Default */
        NOTIFICATION_LY_NOTI_EVENT_SINGLE,
-        /**< Layout for notification. Used to inform single event*/
+       /**< Layout for notification. Used to inform single event*/
        NOTIFICATION_LY_NOTI_EVENT_MULTIPLE,
-        /**< Layout for notification. Used to inform multiple event*/
+       /**< Layout for notification. Used to inform multiple event*/
        NOTIFICATION_LY_NOTI_THUMBNAIL,
-        /**< Layout for notification. Used to display images*/
+       /**< Layout for notification. Used to display images*/
        NOTIFICATION_LY_ONGOING_EVENT,
-        /**< Layout for ongoing notification. Used to display text message.
-         * notifications with NOTIFICATION_LY_ONGOING_EVENT can not be protected from removing by user since tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif */
+       /**< Layout for ongoing notification. Used to display text message.
+        * notifications with NOTIFICATION_LY_ONGOING_EVENT can not be protected from removing by user since tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif */
        NOTIFICATION_LY_ONGOING_PROGRESS,
-        /**< Layout for ongoing notification. Used to display progress*/
+       /**< Layout for ongoing notification. Used to display progress*/
        NOTIFICATION_LY_MAX,
-               /**< TBD */
+       /**< TBD */
 } notification_ly_type_e;
 
 /**
@@ -74,7 +69,7 @@ typedef enum _notification_ly_type {
  */
 typedef enum  _notification_launch_option_type {
        NOTIFICATION_LAUNCH_OPTION_APP_CONTROL = 1,
-                                       /**< launching with app control */
+       /**< launching with app control */
 } notification_launch_option_type;
 
 /**
@@ -113,10 +108,10 @@ typedef enum _notification_sound_type {
  */
 typedef enum _notification_vibration_type {
        NOTIFICATION_VIBRATION_TYPE_NONE = -1,
-                    /**< Default value. No vibration */
+       /**< Default value. No vibration */
        NOTIFICATION_VIBRATION_TYPE_DEFAULT = 0,/**< Default vibrate pattern */
        NOTIFICATION_VIBRATION_TYPE_USER_DATA,
-                                       /**< User vibration data */
+       /**< User vibration data */
        NOTIFICATION_VIBRATION_TYPE_MAX,
 } notification_vibration_type_e;
 
@@ -422,9 +417,9 @@ typedef struct _notification_op {
  * @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif
  */
 typedef enum notification_permission_type {
-    NOTIFICATION_PERMISSION_TYPE_NONE = 0,
-    NOTIFICATION_PERMISSION_TYPE_DELETE = 1,
-    NOTIFICATION_PERMISSION_TYPE_UPDATE = 2,
+       NOTIFICATION_PERMISSION_TYPE_NONE = 0,
+       NOTIFICATION_PERMISSION_TYPE_DELETE = 1,
+       NOTIFICATION_PERMISSION_TYPE_UPDATE = 2,
 } notification_permission_type_e;
 
 /**
@@ -434,4 +429,5 @@ typedef enum notification_permission_type {
 #ifdef __cplusplus
 }
 #endif
-#endif                         /* __NOTIFICATION_TYPE_H__ */
+#endif /* __NOTIFICATION_TYPE_H__ */
+
index 7eb7606..e6d91a9 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
@@ -196,8 +191,7 @@ EXPORT_API int notification_get_image(notification_h noti,
        return NOTIFICATION_ERROR_NONE;
 }
 
-EXPORT_API int notification_set_time(notification_h noti,
-                                                     time_t input_time)
+EXPORT_API int notification_set_time(notification_h noti, time_t input_time)
 {
        /* Check noti is valid data */
        if (noti == NULL)
@@ -213,8 +207,7 @@ EXPORT_API int notification_set_time(notification_h noti,
        return NOTIFICATION_ERROR_NONE;
 }
 
-EXPORT_API int notification_get_time(notification_h noti,
-                                                     time_t * ret_time)
+EXPORT_API int notification_get_time(notification_h noti, time_t *ret_time)
 {
        /* Check noti and time is valid data */
        if (noti == NULL || ret_time == NULL)
@@ -227,7 +220,7 @@ EXPORT_API int notification_get_time(notification_h noti,
 }
 
 EXPORT_API int notification_get_insert_time(notification_h noti,
-                                                            time_t * ret_time)
+               time_t *ret_time)
 {
        /* Check noti and ret_time is valid data */
        if (noti == NULL || ret_time == NULL)
@@ -240,10 +233,8 @@ EXPORT_API int notification_get_insert_time(notification_h noti,
 }
 
 EXPORT_API int notification_set_text(notification_h noti,
-                                                     notification_text_type_e type,
-                                                     const char *text,
-                                                     const char *key,
-                                                     int args_type, ...)
+               notification_text_type_e type, const char *text,
+               const char *key, int args_type, ...)
 {
        bundle *b = NULL;
        char buf_key[32] = { 0, };
@@ -1695,7 +1686,7 @@ EXPORT_API notification_h  notification_load_by_tag(const char *tag)
                return NULL;
        }
 
-       ret = notification_ipc_request_load_noti_by_tag(noti, caller_pkgname, (char*)tag);
+       ret = notification_ipc_request_load_noti_by_tag(noti, caller_pkgname, (char *)tag);
        free(caller_pkgname);
 
        set_last_result(ret);
@@ -1959,7 +1950,7 @@ EXPORT_API int notification_get_tag(notification_h noti, const char **tag)
 void notification_call_posted_toast_cb(const char *message)
 {
        if (posted_toast_message_cb != NULL)
-               posted_toast_message_cb((void*)message);
+               posted_toast_message_cb((void *)message);
 }
 
 EXPORT_API int notification_set_ongoing_flag(notification_h noti, bool ongoing_flag)
@@ -2023,3 +2014,4 @@ EXPORT_API int notification_get_auto_remove(notification_h noti, bool *auto_remo
 
        return NOTIFICATION_ERROR_NONE;
 }
+
index a89188b..e74c75b 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <errno.h>
@@ -32,7 +27,7 @@
 #include <notification_debug.h>
 #include <notification_db.h>
 
-sqlite3 * notification_db_open(const char *dbfile)
+sqlite3 *notification_db_open(const char *dbfile)
 {
        int ret = 0;
        sqlite3 *db = 0;
@@ -50,7 +45,7 @@ sqlite3 * notification_db_open(const char *dbfile)
        return db;
 }
 
-int notification_db_close(sqlite3 ** db)
+int notification_db_close(sqlite3 **db)
 {
        int ret = 0;
 
@@ -68,7 +63,7 @@ int notification_db_close(sqlite3 ** db)
        return NOTIFICATION_ERROR_NONE;
 }
 
-int notification_db_exec(sqlite3 * db, const char *query, int *num_changes)
+int notification_db_exec(sqlite3 *db, const char *query, int *num_changes)
 {
        int ret = 0;
        sqlite3_stmt *stmt = NULL;
@@ -127,3 +122,4 @@ bundle *notification_db_column_bundle(sqlite3_stmt * stmt, int col)
 
        return bundle_decode(col_bundle, strlen((char *)col_bundle));
 }
+
index 1ed2317..deceec5 100644 (file)
@@ -1,6 +1,4 @@
 /*
- *  libnotification
- *
  * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <gio/gio.h>
 #include "notification_error.h"
 
-static const GDBusErrorEntry dbus_error_entries[] =
-{
+static const GDBusErrorEntry dbus_error_entries[] = {
        {NOTIFICATION_ERROR_INVALID_PARAMETER, "org.freedesktop.Notification.Error.INVALID_PARAMETER"},
        {NOTIFICATION_ERROR_OUT_OF_MEMORY,     "org.freedesktop.Notification.Error.OUT_OF_MEMORY"},
        {NOTIFICATION_ERROR_IO_ERROR,          "org.freedesktop.Notification.Error.IO_ERROR"},
@@ -34,13 +30,13 @@ static const GDBusErrorEntry dbus_error_entries[] =
        {NOTIFICATION_ERROR_INVALID_OPERATION, "org.freedesktop.Notification.Error.INVALID_OPERATION"},
 };
 
-EXPORT_API GQuark notification_error_quark (void)
+EXPORT_API GQuark notification_error_quark(void)
 {
        static volatile gsize quark_volatile = 0;
-       g_dbus_error_register_error_domain ("notification-error-quark",
+       g_dbus_error_register_error_domain("notification-error-quark",
                        &quark_volatile,
                        dbus_error_entries,
                        G_N_ELEMENTS(dbus_error_entries));
-       return (GQuark) quark_volatile;
+       return (GQuark)quark_volatile;
 }
 
index 21927ea..455545a 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
@@ -28,7 +23,7 @@
 #include <notification_db.h>
 
 static int _notification_group_check_data_inserted(const char *pkgname,
-                                                  int group_id, sqlite3 * db)
+                                                  int group_id, sqlite3 *db)
 {
        sqlite3_stmt *stmt = NULL;
        char query[NOTIFICATION_QUERY_MAX] = { 0, };
@@ -191,3 +186,4 @@ int notification_group_get_badge(const char *pkgname,
 
        return NOTIFICATION_ERROR_NONE;
 }
+
index 1ef0dac..466e9c9 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
@@ -460,9 +455,8 @@ EXPORT_API int notification_get_application(notification_h noti,
        return NOTIFICATION_ERROR_NONE;
 }
 
-EXPORT_API int notification_set_args(notification_h noti,
-                                                     bundle * args,
-                                                     bundle * group_args)
+EXPORT_API int notification_set_args(notification_h noti, bundle *args,
+               bundle *group_args)
 {
        if (noti == NULL || args == NULL)
                return NOTIFICATION_ERROR_INVALID_PARAMETER;
@@ -484,8 +478,8 @@ EXPORT_API int notification_set_args(notification_h noti,
 }
 
 EXPORT_API int notification_get_args(notification_h noti,
-                                                     bundle ** args,
-                                                     bundle ** group_args)
+                                                     bundle **args,
+                                                     bundle **group_args)
 {
        if (noti == NULL || args == NULL)
                return NOTIFICATION_ERROR_INVALID_PARAMETER;
@@ -502,7 +496,7 @@ EXPORT_API int notification_get_args(notification_h noti,
 }
 
 EXPORT_API int notification_get_grouping_list(notification_type_e type, int count,
-                              notification_list_h * list)
+                              notification_list_h *list)
 {
        notification_list_h get_list = NULL;
        int ret = 0;
@@ -608,19 +602,19 @@ EXPORT_API int notification_op_get_data(notification_op *noti_op, notification_o
 
        switch (type) {
        case NOTIFICATION_OP_DATA_TYPE:
-               *((int*)data) = noti_op->type;
+               *((int *)data) = noti_op->type;
                break;
        case NOTIFICATION_OP_DATA_PRIV_ID:
-               *((int*)data) = noti_op->priv_id;
+               *((int *)data) = noti_op->priv_id;
                break;
        case NOTIFICATION_OP_DATA_NOTI:
                *((notification_h *)data) = noti_op->noti;
                break;
        case NOTIFICATION_OP_DATA_EXTRA_INFO_1:
-               *((int*)data) = noti_op->extra_info_1;
+               *((int *)data) = noti_op->extra_info_1;
                break;
        case NOTIFICATION_OP_DATA_EXTRA_INFO_2:
-               *((int*)data) = noti_op->extra_info_2;
+               *((int *)data) = noti_op->extra_info_2;
                break;
        default:
                return NOTIFICATION_ERROR_INVALID_PARAMETER;
@@ -1075,3 +1069,4 @@ EXPORT_API int notification_is_service_ready(void)
 {
        return notification_ipc_is_master_ready();
 }
+
index 9213bc7..4ce6465 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
@@ -72,7 +67,8 @@ static int _ipc_monitor_register(void);
 static int _ipc_monitor_deregister(void);
 static void _do_deffered_task(void);
 
-static void _print_noti(notification_h noti) {
+static void _print_noti(notification_h noti)
+{
        char *pkgname = NULL;
        char *text = NULL;
        char *content = NULL;
@@ -85,10 +81,10 @@ static void _print_noti(notification_h noti) {
        notification_get_tag(noti, &tag);
        notification_get_vibration(noti, &vib_type, NULL);
 
-       NOTIFICATION_DBG("client print_noti  pkgname  = %s ", pkgname );
-       NOTIFICATION_DBG("client print_noti  title  = %s ", text );
-       NOTIFICATION_DBG("client print_noti  content  = %s ", content );
-       NOTIFICATION_DBG("client print_noti  tag  = %s ", tag );
+       NOTIFICATION_DBG("client print_noti  pkgname  = %s ", pkgname);
+       NOTIFICATION_DBG("client print_noti  title  = %s ", text);
+       NOTIFICATION_DBG("client print_noti  content  = %s ", content);
+       NOTIFICATION_DBG("client print_noti  tag  = %s ", tag);
        NOTIFICATION_DBG("client print_noti  priv_id  = %d ", noti->priv_id);
        NOTIFICATION_DBG("client print_noti  vibration_path  = %s ", noti->vibration_path);
        NOTIFICATION_DBG("client print_noti  vibration_type  = %d ", vib_type);
@@ -144,7 +140,7 @@ int notification_ipc_is_master_ready(void)
                }
        }
 
-       if(result)
+       if (result)
                g_variant_unref(result);
 
        return is_master_started;
@@ -683,7 +679,7 @@ int notification_ipc_request_insert(notification_h noti, int *priv_id)
                        *priv_id = id;
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_insert done [priv_id : %d, result: %d]", id, result);
@@ -717,7 +713,7 @@ int notification_ipc_request_update(notification_h noti)
                g_variant_get(reply_body, "(i)", &priv_id);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_update done [result: %d, priv_id :%d]", result, priv_id);
@@ -779,7 +775,7 @@ int notification_ipc_request_refresh(void)
        body = g_variant_new("(i)", NOTIFICATION_OP_REFRESH);
        result = _send_sync_noti(body, &reply, "refresh_noti");
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_ERR("notification_ipc_request_refresh done [result: %d]", result);
@@ -808,7 +804,7 @@ int notification_ipc_request_delete_single(notification_type_e type, char *pkgna
                g_variant_get(reply_body, "(i)", &id);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_ERR("notification_ipc_request_delete_single done [result: %d]", result);
@@ -841,7 +837,7 @@ int notification_ipc_request_delete_multiple(notification_type_e type, char *pkg
                NOTIFICATION_ERR("num deleted:%d", num_deleted);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        return result;
@@ -877,7 +873,7 @@ int notification_ipc_request_load_noti_by_tag(notification_h noti, const char *p
 
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_load_noti_by_tag done [result: %d]", result);
@@ -913,7 +909,7 @@ int notification_ipc_request_load_noti_by_priv_id(notification_h noti, const cha
                _print_noti(noti);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_load_noti_by_priv_id done [result: %d]", result);
@@ -949,7 +945,7 @@ int notification_ipc_request_get_count(notification_type_e type,
                NOTIFICATION_DBG("noti count [%d]", re_count);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_get_count done [result: %d]", result);
@@ -991,7 +987,7 @@ int notification_ipc_request_load_noti_grouping_list(notification_type_e type, i
                g_variant_iter_free(iter);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_load_noti_grouping_list done [result: %d]", result);
@@ -1036,7 +1032,7 @@ int notification_ipc_request_load_noti_detail_list(const char *pkgname,
                g_variant_iter_free(iter);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_load_noti_detail_list done [result: %d]", result);
@@ -1090,7 +1086,7 @@ int notification_ipc_request_get_setting_array(
                g_variant_iter_free(iter);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_get_setting_array done [result: %d]", result);
@@ -1133,7 +1129,7 @@ int notification_ipc_request_get_setting_by_package_name(
                g_variant_unref(setting_body);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_get_setting_by_package_name done [result: %d]", result);
@@ -1172,7 +1168,7 @@ int notification_ipc_request_load_system_setting(notification_system_setting_h *
                g_variant_unref(setting_body);
        }
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_request_load_system_setting done [result: %d]", result);
@@ -1199,7 +1195,7 @@ int notification_ipc_update_setting(notification_setting_h setting)
 
        result = _send_sync_noti(body, &reply, "update_noti_setting");
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_DBG("notification_ipc_update_setting done [result: %d]", result);
@@ -1430,8 +1426,8 @@ EXPORT_API GVariant *notification_ipc_make_gvariant_from_noti(notification_h not
        return body;
 }
 
-static gboolean _variant_to_int_dict(GHashTable **dict, GVariant *variant) {
-
+static gboolean _variant_to_int_dict(GHashTable **dict, GVariant *variant)
+{
        GVariantIter iter;
        int key;
        int *hash_key;
@@ -1694,7 +1690,7 @@ static int _send_service_register()
 
        result = _send_sync_noti(NULL, &reply, "noti_service_register");
 
-       if(reply)
+       if (reply)
                g_object_unref(reply);
 
        NOTIFICATION_ERR("_send_service_register done = %s, result = %d", _bus_name, result);
@@ -1791,3 +1787,4 @@ int notification_ipc_monitor_fini(void)
 {
        return  _ipc_monitor_deregister();
 }
+
index 078dc29..1012732 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdlib.h>
@@ -288,3 +283,4 @@ EXPORT_API int notification_free_list(notification_list_h list)
 
        return NOTIFICATION_ERROR_NONE;
 }
+
index d0510c4..1ca42eb 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
@@ -53,7 +48,7 @@ static void __free_and_set(void **target_ptr, void *new_ptr)
        }
 }
 
-static int _notification_noti_bind_query_text(sqlite3_stmt * stmt, const char *name,
+static int _notification_noti_bind_query_text(sqlite3_stmt *stmt, const char *name,
                                         const char *str)
 {
        int ret = 0;
@@ -77,7 +72,7 @@ static int _notification_noti_bind_query_text(sqlite3_stmt * stmt, const char *n
        return NOTIFICATION_ERROR_NONE;
 }
 
-static int _notification_noti_bind_query_double(sqlite3_stmt * stmt, const char *name,
+static int _notification_noti_bind_query_double(sqlite3_stmt *stmt, const char *name,
                                         double val)
 {
        int ret = 0;
@@ -98,7 +93,7 @@ static int _notification_noti_bind_query_double(sqlite3_stmt * stmt, const char
        return NOTIFICATION_ERROR_NONE;
 }
 
-static int _notification_noti_check_priv_id(notification_h noti, sqlite3 * db)
+static int _notification_noti_check_priv_id(notification_h noti, sqlite3 *db)
 {
        int result = 0;
        int ret = NOTIFICATION_ERROR_NONE;
@@ -142,7 +137,7 @@ err:
 
 static int _notification_noti_get_internal_group_id_by_priv_id(const char *pkgname,
                                                               int priv_id,
-                                                              sqlite3 * db)
+                                                              sqlite3 *db)
 {
        char *query = NULL;
        sqlite3_stmt *stmt = NULL;
@@ -204,48 +199,48 @@ static int _insertion_query_create(notification_h noti, char **query)
 
        /* Decode bundle to insert DB */
        if (noti->args)
-               bundle_encode(noti->args, (bundle_raw **) & args, &b_encode_len);
+               bundle_encode(noti->args, (bundle_raw **)&args, &b_encode_len);
 
        if (noti->group_args)
-               bundle_encode(noti->group_args, (bundle_raw **) & group_args,
+               bundle_encode(noti->group_args, (bundle_raw **)&group_args,
                              &b_encode_len);
 
        if (noti->b_execute_option)
                bundle_encode(noti->b_execute_option,
-                             (bundle_raw **) & b_execute_option, &b_encode_len);
+                             (bundle_raw **)&b_execute_option, &b_encode_len);
 
        if (noti->b_service_responding)
                bundle_encode(noti->b_service_responding,
-                             (bundle_raw **) & b_service_responding, &b_encode_len);
+                             (bundle_raw **)&b_service_responding, &b_encode_len);
 
        if (noti->b_service_single_launch)
                bundle_encode(noti->b_service_single_launch,
-                             (bundle_raw **) & b_service_single_launch, &b_encode_len);
+                             (bundle_raw **)&b_service_single_launch, &b_encode_len);
 
        if (noti->b_service_multi_launch)
                bundle_encode(noti->b_service_multi_launch,
-                             (bundle_raw **) & b_service_multi_launch, &b_encode_len);
+                             (bundle_raw **)&b_service_multi_launch, &b_encode_len);
 
 
        for (i = 0; i < NOTIFICATION_EVENT_TYPE_MAX; i++) {
                if (noti->b_event_handler[i])
                        bundle_encode(noti->b_event_handler[i],
-                                       (bundle_raw **) & b_event_handler[i], &b_encode_len);
+                                       (bundle_raw **)&b_event_handler[i], &b_encode_len);
        }
 
        if (noti->b_text)
-               bundle_encode(noti->b_text, (bundle_raw **) & b_text, &b_encode_len);
+               bundle_encode(noti->b_text, (bundle_raw **)&b_text, &b_encode_len);
 
        if (noti->b_key)
-               bundle_encode(noti->b_key, (bundle_raw **) & b_key, &b_encode_len);
+               bundle_encode(noti->b_key, (bundle_raw **)&b_key, &b_encode_len);
 
        if (noti->b_format_args)
                bundle_encode(noti->b_format_args,
-                             (bundle_raw **) & b_format_args, &b_encode_len);
+                             (bundle_raw **)&b_format_args, &b_encode_len);
 
        if (noti->b_image_path)
                bundle_encode(noti->b_image_path,
-                             (bundle_raw **) & b_image_path, &b_encode_len);
+                             (bundle_raw **)&b_image_path, &b_encode_len);
 
        /* Check only simmode property is enable */
        if (noti->flags_for_property & NOTIFICATION_PROP_DISPLAY_ONLY_SIMMODE)
@@ -383,47 +378,47 @@ static int _update_query_create(notification_h noti, char **query)
 
        /* Decode bundle to update DB */
        if (noti->args)
-               bundle_encode(noti->args, (bundle_raw **) & args, &b_encode_len);
+               bundle_encode(noti->args, (bundle_raw **)&args, &b_encode_len);
 
        if (noti->group_args)
-               bundle_encode(noti->group_args, (bundle_raw **) & group_args,
+               bundle_encode(noti->group_args, (bundle_raw **)&group_args,
                              &b_encode_len);
 
        if (noti->b_execute_option)
                bundle_encode(noti->b_execute_option,
-                             (bundle_raw **) & b_execute_option, &b_encode_len);
+                             (bundle_raw **)&b_execute_option, &b_encode_len);
 
        if (noti->b_service_responding)
                bundle_encode(noti->b_service_responding,
-                             (bundle_raw **) & b_service_responding, &b_encode_len);
+                             (bundle_raw **)&b_service_responding, &b_encode_len);
 
        if (noti->b_service_single_launch)
                bundle_encode(noti->b_service_single_launch,
-                             (bundle_raw **) & b_service_single_launch, &b_encode_len);
+                             (bundle_raw **)&b_service_single_launch, &b_encode_len);
 
        if (noti->b_service_multi_launch)
                bundle_encode(noti->b_service_multi_launch,
-                             (bundle_raw **) & b_service_multi_launch, &b_encode_len);
+                             (bundle_raw **)&b_service_multi_launch, &b_encode_len);
 
        for (i = 0; i < NOTIFICATION_EVENT_TYPE_MAX; i++) {
                if (noti->b_event_handler[i])
                        bundle_encode(noti->b_event_handler[i],
-                                       (bundle_raw **) & b_event_handler[i], &b_encode_len);
+                                       (bundle_raw **)&b_event_handler[i], &b_encode_len);
        }
 
        if (noti->b_text)
-               bundle_encode(noti->b_text, (bundle_raw **) & b_text, &b_encode_len);
+               bundle_encode(noti->b_text, (bundle_raw **)&b_text, &b_encode_len);
 
        if (noti->b_key)
-               bundle_encode(noti->b_key, (bundle_raw **) & b_key, &b_encode_len);
+               bundle_encode(noti->b_key, (bundle_raw **)&b_key, &b_encode_len);
 
        if (noti->b_format_args)
                bundle_encode(noti->b_format_args,
-                             (bundle_raw **) & b_format_args, &b_encode_len);
+                             (bundle_raw **)&b_format_args, &b_encode_len);
 
        if (noti->b_image_path)
                bundle_encode(noti->b_image_path,
-                             (bundle_raw **) & b_image_path, &b_encode_len);
+                             (bundle_raw **)&b_image_path, &b_encode_len);
 
        /* Check only simmode property is enable */
        if (noti->flags_for_property & NOTIFICATION_PROP_DISPLAY_ONLY_SIMMODE)
@@ -531,7 +526,7 @@ static int _update_query_create(notification_h noti, char **query)
        return NOTIFICATION_ERROR_NONE;
 }
 
-static void _notification_noti_populate_from_stmt(sqlite3_stmt * stmt, notification_h noti)
+static void _notification_noti_populate_from_stmt(sqlite3_stmt *stmt, notification_h noti)
 {
        int col = 0;
        int i = 0;
@@ -596,7 +591,7 @@ static void _notification_noti_populate_from_stmt(sqlite3_stmt * stmt, notificat
        noti->temp_content = NULL;
 }
 
-static notification_h _notification_noti_get_item(sqlite3_stmt * stmt)
+static notification_h _notification_noti_get_item(sqlite3_stmt *stmt)
 {
        notification_h noti = NULL;
 
@@ -665,7 +660,7 @@ int notification_noti_get_tag_type(const char *tagged_str)
        return TAG_TYPE_INVALID;
 }
 
-static int _notification_noti_update_priv_id(sqlite3 * db, int rowid)
+static int _notification_noti_update_priv_id(sqlite3 *db, int rowid)
 {
        int ret = NOTIFICATION_ERROR_NONE;
        char *query = NULL;
@@ -876,7 +871,7 @@ EXPORT_API int notification_noti_insert(notification_h noti)
                return NOTIFICATION_ERROR_INVALID_PARAMETER;
        }
 
-       if (_is_allowed_to_notify((const char*)noti->caller_pkgname) == false) {
+       if (_is_allowed_to_notify((const char *)noti->caller_pkgname) == false) {
                NOTIFICATION_DBG("[%s] is not allowed to notify", noti->caller_pkgname);
                return NOTIFICATION_ERROR_PERMISSION_DENIED;
        }
@@ -1146,7 +1141,7 @@ EXPORT_API int notification_noti_update(notification_h noti)
        if (!db)
                return get_last_result();
 
-       if (_is_allowed_to_notify((const char*)noti->caller_pkgname) == false) {
+       if (_is_allowed_to_notify((const char *)noti->caller_pkgname) == false) {
                NOTIFICATION_DBG("[%s] is not allowed to notify", noti->caller_pkgname);
                return NOTIFICATION_ERROR_PERMISSION_DENIED;
        }
@@ -1952,3 +1947,4 @@ err:
 
        return ret;
 }
+
index 565496e..699338a 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
index ef472c6..73d2d8b 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
index a2d6fd1..0b34177 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <stdio.h>
index b9bfbab..478ca28 100644 (file)
@@ -1,6 +1,4 @@
 /*
- *  libnotification
- *
  * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
@@ -14,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <errno.h>
@@ -141,7 +138,7 @@ EXPORT_API int noti_setting_service_get_setting_by_package_name(const char *pack
 
        row_count = 1;
 
-       if (!(result_setting_array = (struct notification_setting*)malloc(sizeof(struct notification_setting) * row_count))) {
+       if (!(result_setting_array = (struct notification_setting *)malloc(sizeof(struct notification_setting) * row_count))) {
                NOTIFICATION_ERR("malloc failed...");
                err = NOTIFICATION_ERROR_OUT_OF_MEMORY;
                goto out;
@@ -150,8 +147,8 @@ EXPORT_API int noti_setting_service_get_setting_by_package_name(const char *pack
        col_index = column_count;
 
        _get_table_field_data_string(query_result, &(result_setting_array[i].package_name), 1, col_index++);
-       _get_table_field_data_int(query_result, (int*)&(result_setting_array[i].allow_to_notify), col_index++);
-       _get_table_field_data_int(query_result, (int*)&(result_setting_array[i].do_not_disturb_except), col_index++);
+       _get_table_field_data_int(query_result, (int *)&(result_setting_array[i].allow_to_notify), col_index++);
+       _get_table_field_data_int(query_result, (int *)&(result_setting_array[i].do_not_disturb_except), col_index++);
        _get_table_field_data_int(query_result, &(result_setting_array[i].visibility_class), col_index++);
 
        *setting = result_setting_array;
@@ -226,7 +223,7 @@ EXPORT_API int noti_setting_get_setting_array(notification_setting_h *setting_ar
        }
 
        NOTIFICATION_DBG("row_count [%d] column_count [%d]", row_count, column_count);
-       if (!(result_setting_array = (struct notification_setting*)malloc(sizeof(struct notification_setting) * row_count))) {
+       if (!(result_setting_array = (struct notification_setting *)malloc(sizeof(struct notification_setting) * row_count))) {
                NOTIFICATION_ERR("malloc failed...");
                err = NOTIFICATION_ERROR_OUT_OF_MEMORY;
                goto out;
@@ -236,8 +233,8 @@ EXPORT_API int noti_setting_get_setting_array(notification_setting_h *setting_ar
 
        for (i = 0; i < row_count; i++) {
                _get_table_field_data_string(query_result, &(result_setting_array[i].package_name), 1, col_index++);
-               _get_table_field_data_int(query_result, (int*)&(result_setting_array[i].allow_to_notify), col_index++);
-               _get_table_field_data_int(query_result, (int*)&(result_setting_array[i].do_not_disturb_except), col_index++);
+               _get_table_field_data_int(query_result, (int *)&(result_setting_array[i].allow_to_notify), col_index++);
+               _get_table_field_data_int(query_result, (int *)&(result_setting_array[i].do_not_disturb_except), col_index++);
                _get_table_field_data_int(query_result, &(result_setting_array[i].visibility_class), col_index++);
        }
 
@@ -314,7 +311,7 @@ EXPORT_API int noti_system_setting_load_system_setting(notification_system_setti
 
        row_count = 1;
 
-       if (!(result_system_setting = (struct notification_system_setting*)malloc(sizeof(struct notification_system_setting)))) {
+       if (!(result_system_setting = (struct notification_system_setting *)malloc(sizeof(struct notification_system_setting)))) {
                NOTIFICATION_ERR("malloc failed...");
                err = NOTIFICATION_ERROR_OUT_OF_MEMORY;
                goto out;
@@ -322,7 +319,7 @@ EXPORT_API int noti_system_setting_load_system_setting(notification_system_setti
 
        col_index = column_count;
 
-       _get_table_field_data_int(query_result, (int*)&(result_system_setting->do_not_disturb), col_index++);
+       _get_table_field_data_int(query_result, (int *)&(result_system_setting->do_not_disturb), col_index++);
        _get_table_field_data_int(query_result, &(result_system_setting->visibility_class), col_index++);
 
        *system_setting = result_system_setting;
@@ -343,6 +340,3 @@ out:
        return err;
 }
 
-
-
-
index 6ca7275..377162a 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  libnotification
- *
- * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Seungtaek Chung <seungtaek.chung@samsung.com>, Mi-Ju Lee <miju52.lee@samsung.com>, Xi Zhichan <zhichan.xi@samsung.com>
+ * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -16,7 +12,6 @@
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
 #include <sys/types.h>
index 79a0a47..35f28ee 100755 (executable)
@@ -1,9 +1,5 @@
 /*
- *  Test application for notification API
- *
- * Copyright (c) 2015 Samsung Electronics Co., Ltd. All rights reserved.
- *
- * Contact: Kyuho Jo <kyuho.jo@samsung.com>
+ * Copyright (c) 2015 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- *
  */
 
-
-
 /* common header */
 #include <stdio.h>
 #include <stdlib.h>
@@ -284,7 +277,7 @@ static int testapp_test_post_notification_on_indicator()
        noti_err  = notification_set_image(noti_handle, NOTIFICATION_IMAGE_TYPE_ICON_FOR_INDICATOR, image_path);
        /*
        noti_err  = notification_set_text(noti_handle, NOTIFICATION_TEXT_TYPE_TITLE, "I'm Title", "TITLE", NOTIFICATION_VARIABLE_TYPE_NONE);
-       noti_err  = notification_set_text(noti_handle, NOTIFICATION_TEXT_TYPE_CONTENT, "I'm Content", "This is very loooooooooooooooooooooooooooooooooooooooooong message", NOTIFICATION_VARIABLE_TYPE_NONE);
+       noti_err  = notification_set_text(noti_handle, NOTIFICATION_TEXT_TYPE_CONTENT, "I'm Content", "This is very long message", NOTIFICATION_VARIABLE_TYPE_NONE);
        */
        noti_err  = notification_set_display_applist(noti_handle, NOTIFICATION_DISPLAY_APP_TICKER | NOTIFICATION_DISPLAY_APP_INDICATOR);