From 17fd00c16951b025952001c0d815203bb57bd4d9 Mon Sep 17 00:00:00 2001
From: Davin <591807572@qq.com>
Date: 星期一, 31 七月 2023 18:41:38 +0800
Subject: [PATCH] Merge branch 'Dev-Branch' of http://59.41.255.150:6688/r/~wxr/OnPro into Dev-Branch

---
 HDL_ON/Common/ApiUtlis.cs |   36 ++++++++++++++++++++++++++++++------
 1 files changed, 30 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs
index e6f4a51..5272390 100644
--- a/HDL_ON/Common/ApiUtlis.cs
+++ b/HDL_ON/Common/ApiUtlis.cs
@@ -106,8 +106,16 @@
                 {
                     if (waitPage != null)
                     {
-                        waitPage.RemoveFromParent();
-                        waitPage = null;
+                        Application.RunOnMainThread(() =>
+                        {
+                            try
+                            {
+                                waitPage.Hide();
+                                waitPage.RemoveFromParent();
+                                waitPage = null;
+                            }
+                            catch { }
+                        });
                     }
                     MainPage.Log($"鍒锋柊token澶辫触");
                     return;
@@ -119,8 +127,16 @@
                 {
                     if (waitPage != null)
                     {
-                        waitPage.RemoveFromParent();
-                        waitPage = null;
+                        Application.RunOnMainThread(() =>
+                        {
+                            try
+                            {
+                                waitPage.Hide();
+                                waitPage.RemoveFromParent();
+                                waitPage = null;
+                            }
+                            catch { }
+                        });
                     }
                     MainPage.Log($"鍒锋柊浣忓畢淇℃伅澶辫触");
                     return;
@@ -132,8 +148,16 @@
                 {
                     if (waitPage != null)
                     {
-                        waitPage.RemoveFromParent();
-                        waitPage = null;
+                        Application.RunOnMainThread(() =>
+                        {
+                            try
+                            {
+                                waitPage.Hide();
+                                waitPage.RemoveFromParent();
+                                waitPage = null;
+                            }
+                            catch { }
+                        });
                     }
                     MainPage.Log($"鍒锋柊涓汉淇℃伅澶辫触");
                     return;

--
Gitblit v1.8.0