From e1ce1fc4889d5e52ca2b1f75b3f98d10c1799a5e Mon Sep 17 00:00:00 2001 From: mk5004lee <37102375+mk5004lee@users.noreply.github.com> Date: Tue, 6 Mar 2018 09:50:41 +0000 Subject: [PATCH] [Notification] Save the hidetime, deletetime value (#140) - regardless of IsAutoRemove Signed-off-by: mk5004.lee --- .../NotificationStyleBinder.cs | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/Tizen.Applications.Notification/Tizen.Applications.Notifications/NotificationStyleBinder.cs b/src/Tizen.Applications.Notification/Tizen.Applications.Notifications/NotificationStyleBinder.cs index 5824a18..8b837bc 100755 --- a/src/Tizen.Applications.Notification/Tizen.Applications.Notifications/NotificationStyleBinder.cs +++ b/src/Tizen.Applications.Notification/Tizen.Applications.Notifications/NotificationStyleBinder.cs @@ -72,17 +72,22 @@ namespace Tizen.Applications.Notifications internal static void BindObject(Notification notification) { int flag; + int hidetime = 0; + int deletetime = 0; NotificationError ret = NotificationError.None; Notification.ActiveStyle style = (Notification.ActiveStyle)notification.GetStyle("Active"); Interop.Notification.SetAutoRemove(notification.Handle, style.IsAutoRemove); - if (style.IsAutoRemove == true) - { - int hidetime; - int deletetime; - style.GetRemoveTime(out hidetime, out deletetime); + style.GetRemoveTime(out hidetime, out deletetime); + + if (hidetime > 0) + { Interop.Notification.SetHideTime(notification.Handle, hidetime); + } + + if (deletetime > 0) + { try { Interop.Notification.SetDeleteTime(notification.Handle, deletetime); -- 2.7.4