Fixed Apps loading view never ends. 91/317591/1
authorCORP\mobaswirul.i <mobaswirul.i@samsung.com>
Thu, 12 Sep 2024 04:41:23 +0000 (10:41 +0600)
committerCORP\mobaswirul.i <mobaswirul.i@samsung.com>
Thu, 12 Sep 2024 04:41:23 +0000 (10:41 +0600)
[Problem] [TNINE-4447] Apps loading view never ends.

[Cause & Measure]
 Cause   : OnPageAppeared was not invoked after adding.
 Measure : Invoked OnPageAppeared after adding the view.

Change-Id: I72342f635af578a11bb305861d102c4e633ec4fe

SettingCore/GadgetNavigation.cs
packaging/org.tizen.cssettings-1.2.1.tpk

index 373a4c7ec36d46571db4dcf7c77c8c52f4eab6b4..f07c9a80a8e4c981a6b5ff08e37963a8245356aa 100644 (file)
@@ -106,7 +106,7 @@ namespace SettingCore
 
                     try
                     {
-                        AddGadgetView(contentPage);
+                        AddGadgetView(contentPage, gadget);
                     }
                     catch (Exception ex)
                     {
@@ -158,12 +158,7 @@ namespace SettingCore
                     ThemeChangeSensitive = true,
                 };
 
-                page.Appeared += (s, e) =>
-                {
-                    gadget.OnPageAppeared?.Invoke();
-                };
-
-                AddGadgetView(page);
+                AddGadgetView(page, gadget);
                 gadgetPages.Add(page, gadget);
             }
             catch (Exception e)
@@ -176,7 +171,7 @@ namespace SettingCore
             }
         }
 
-        public static void AddGadgetView(View newView)
+        public static void AddGadgetView(View newView, MenuGadget gadget)
         {
             Logger.Debug("Adding New Gadget View");
             View currentView = NUIApplication.GetDefaultWindow().GetDefaultNavigator().GetChildAt(0);
@@ -188,6 +183,7 @@ namespace SettingCore
             gadgetViews.Push(currentView);
             NUIApplication.GetDefaultWindow().GetDefaultNavigator().Remove(currentView);
             NUIApplication.GetDefaultWindow().GetDefaultNavigator().Add(newView);
+            gadget?.OnPageAppeared?.Invoke();
         }
 
         public static void RemoveGadgetView()
index fc9fb8b372b65d60bc1b09824282592216754af0..cd5b93728e2a23b901faaf4619237b5b4bdf0354 100644 (file)
Binary files a/packaging/org.tizen.cssettings-1.2.1.tpk and b/packaging/org.tizen.cssettings-1.2.1.tpk differ