From e74a519b41d2f3541a60d1d738ef2a63d1ea4cdb Mon Sep 17 00:00:00 2001
From: mjsoftware <1406993111@qq.com>
Date: Fri, 21 Feb 2025 09:24:34 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
AdbTools/App.xaml.cs | 4 +---
AdbTools/MainWindow.xaml | 6 +++---
AdbTools/MainWindow.xaml.cs | 3 +--
Update/MainWindow.xaml.cs | 3 +--
4 files changed, 6 insertions(+), 10 deletions(-)
diff --git a/AdbTools/App.xaml.cs b/AdbTools/App.xaml.cs
index 4961737..9112d7c 100644
--- a/AdbTools/App.xaml.cs
+++ b/AdbTools/App.xaml.cs
@@ -33,9 +33,7 @@ namespace AdbTools
if (createMeetingProcess.Count() > 1)
{
HandleRunningInstance(createMeetingProcess[0]);
- ///退出当前新开进程,不走OnExit方法
- Environment.Exit(0);
- //Application.Current.Shutdown();
+ Application.Current.Shutdown();
return;
}
}
diff --git a/AdbTools/MainWindow.xaml b/AdbTools/MainWindow.xaml
index cd4adfa..c7a4807 100644
--- a/AdbTools/MainWindow.xaml
+++ b/AdbTools/MainWindow.xaml
@@ -52,7 +52,7 @@
-
+
@@ -61,8 +61,8 @@
-
-
+
+
diff --git a/AdbTools/MainWindow.xaml.cs b/AdbTools/MainWindow.xaml.cs
index 83e0605..a2aaf2b 100644
--- a/AdbTools/MainWindow.xaml.cs
+++ b/AdbTools/MainWindow.xaml.cs
@@ -525,8 +525,7 @@ namespace AdbTools
if (CmdExecutor.StartExe($"{AppDomain.CurrentDomain.BaseDirectory}Update.exe", cmdArges))
{
- ///退出当前新开进程,不走OnExit方法
- Environment.Exit(0);
+ Application.Current.Shutdown();
}
else
{
diff --git a/Update/MainWindow.xaml.cs b/Update/MainWindow.xaml.cs
index e0a0b5e..de3ce6c 100644
--- a/Update/MainWindow.xaml.cs
+++ b/Update/MainWindow.xaml.cs
@@ -115,8 +115,7 @@ namespace Update
{
this.Dispatcher.Invoke(new Action(() =>
{
- ///退出当前新开进程,不走OnExit方法
- Environment.Exit(0);
+ Application.Current.Shutdown();
}));
}