Fix code to apply changes of Tizen.UI.Color
authorWonYoung Choi <wy80.choi@samsung.com>
Mon, 11 Jul 2016 08:43:41 +0000 (17:43 +0900)
committerWonYoung Choi <wy80.choi@samsung.com>
Mon, 11 Jul 2016 08:43:41 +0000 (17:43 +0900)
The property Argb is changed to a method GetArgb() because this
method can throw an exception when getting the value if the Color
is default (before setting any values).

Change-Id: I8860ad0e3a4b4ec2f3e73d0bd76ce893891ea6e9

Tizen.Applications/Tizen.Applications/Notification.cs

index 7a358e3..2655877 100755 (executable)
@@ -534,7 +534,7 @@ namespace Tizen.Applications.Notifications
                 int ret;
                 if(value)
                 {
-                    ret = Interop.Notification.SetLed(_handle, LedOption.On, _ledColor.Argb);
+                    ret = Interop.Notification.SetLed(_handle, LedOption.On, _ledColor.GetArgb());
                     if(ret != (int)NotificationError.None)
                     {
                         throw NotificationErrorFactory.GetException((NotificationError)ret, "unable to set led enabled");
@@ -584,7 +584,7 @@ namespace Tizen.Applications.Notifications
 
                 if(enabled >= LedOption.On)
                 {
-                    ret = Interop.Notification.SetLed(_handle, LedOption.On, value.Argb);
+                    ret = Interop.Notification.SetLed(_handle, LedOption.On, value.GetArgb());
                     if(ret != (int)NotificationError.None)
                     {
                         throw NotificationErrorFactory.GetException((NotificationError)ret, "unable to set led color");