Customize Notifications Tizen Native Wearable App Development 2.3.2 -
i´m new tizen, , tried develop wearable native app (2.3.2) notifications can created clicking on button. far works, wondering whether notifications customized.
my questions:
- i'd insert button user interaction on notifications. possible? there other way creating button on notification or not possible in tizen 2.3.2 wearables?
- is there way customize popup (automatically?) shown every time new notification created (e.g. add app icon, show part of notification content...)?
- i´m not sure time displayed there @ - seems random me while testing on emulator. possible delete time stamp shown under notification title in notification tray? time stamp on notification should possible modify
notification_set_time(notification, time(null));
, didn't work me. showed random values (not actual system time; samenotification_set_time_to_text
@ code line 9). nothing changed in displayed notification. when tried instead delete time stampnotification_set_time(notification, do_not_show_timestamp)
, gave error(do_not_show_timestamp
unknown).
below part of code covers whole function creates notification , sets content. in line 20 (marked comment) tried add button notification_set_button
, caused error.
void set_notification(appdata_s *ad){ notification_h notification = null; notification = notification_create(notification_type_noti); if(notification != null){ notification_set_text(notification, notification_text_type_title, "alarm", null, notification_variable_type_none); notification_set_time_to_text(notification, time(null), notification_text_type_content); notification_set_text(notification, notification_text_type_content, "failure of valve 4", null, notification_variable_type_none); notification_set_display_applist(notification, notification_display_app_all); notification_set_size(notification, 0.5); notification_set_layout(notification, notification_ly_ongoing_event ); //notification_add_button(notification,notification_button_1); notification_set_vibration(notification, notification_vibration_type_default, null); } app_control_h app_control = null; int noti_err = notification_error_none; app_control_create(&app_control); app_control_set_app_id(app_control, "org.tizen.noti_basicui2"); noti_err = notification_set_launch_option(notification, notification_launch_option_app_control, (void *) app_control); if (noti_err != notification_error_none) { notification_free(notification); return; } app_control_destroy(app_control); notification_post(notification); }
Comments
Post a Comment