handle null reference exception
authorYurii Zinchuk/Tizen Services & IoT (PLT) /SRPOL/Engineer/Samsung Electronics <y.zinchuk@samsung.com>
Tue, 19 Dec 2023 12:51:25 +0000 (13:51 +0100)
committerYurii Zinchuk/Tizen Services & IoT (PLT) /SRPOL/Engineer/Samsung Electronics <y.zinchuk@samsung.com>
Fri, 22 Dec 2023 11:23:36 +0000 (12:23 +0100)
SettingCore/GadgetNavigation.cs

index 3a131359c39ea6db74217003f745d8c97a99809e..264aaa2da36c574953e68b017dcf005cd6cfe41e 100644 (file)
@@ -65,7 +65,16 @@ namespace SettingCore
             else
             {
                 SetFullScreenMode(false);
-                NUIApplication.GetDefaultWindow().GetDefaultNavigator().PopWithTransition();
+
+                try
+                {
+                    // CreateTransitions issue
+                    NUIApplication.GetDefaultWindow().GetDefaultNavigator().PopWithTransition();
+                }
+                catch (Exception ex)
+                {
+                    Logger.Warn($"{ex.Message}");
+                }
             }
         }
 
@@ -103,7 +112,16 @@ namespace SettingCore
                         ThemeChangeSensitive = true,
                     };
 
-                    NUIApplication.GetDefaultWindow().GetDefaultNavigator().PushWithTransition(contentPage);
+                    try
+                    {
+                        // CreateTransitions issue
+                        NUIApplication.GetDefaultWindow().GetDefaultNavigator().PushWithTransition(contentPage);
+                    }
+                    catch (Exception ex)
+                    {
+                        Logger.Warn($"{ex.Message}");
+                    }
+
                     gadgetPages.Add(contentPage, gadget);
                     return;
                 }