From 2fa15e1e4da80cdf3d53e3469972bf290c7c45a4 Mon Sep 17 00:00:00 2001 From: MistEO Date: Tue, 24 Jan 2023 22:35:27 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E4=B8=8D=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=E7=9A=84=E5=85=B3=E6=9C=BA=E9=80=89=E9=A1=B9=E4=B8=8D?= =?UTF-8?q?=E7=94=9F=E6=95=88=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/MaaWpfGui/Main/TaskQueueViewModel.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/MaaWpfGui/Main/TaskQueueViewModel.cs b/src/MaaWpfGui/Main/TaskQueueViewModel.cs index f0c8719c07..9030b760a4 100644 --- a/src/MaaWpfGui/Main/TaskQueueViewModel.cs +++ b/src/MaaWpfGui/Main/TaskQueueViewModel.cs @@ -81,13 +81,6 @@ namespace MaaWpfGui return ActionType.DoNothing; } - if (action == ActionType.HibernateWithoutPersist || action == ActionType.ExitEmulatorAndSelfAndHibernateWithoutPersist - || action == ActionType.ShutdownWithoutPersist) - { - _actionAfterCompleted = ActionType.DoNothing.ToString(); - return ActionType.DoNothing; - } - return action; } @@ -95,6 +88,13 @@ namespace MaaWpfGui { string storeValue = value.ToString(); SetAndNotify(ref _actionAfterCompleted, storeValue); + + if (value == ActionType.HibernateWithoutPersist || value == ActionType.ExitEmulatorAndSelfAndHibernateWithoutPersist + || value == ActionType.ShutdownWithoutPersist) + { + storeValue = ActionType.DoNothing.ToString(); + } + ViewStatusStorage.Set("MainFunction.ActionAfterCompleted", storeValue); } }