From 24542bc4fcfe4df43019fbe9fa8904ae1c90953e Mon Sep 17 00:00:00 2001 From: uye <99072975+ABA2396@users.noreply.github.com> Date: Sat, 28 Dec 2024 16:07:23 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E7=83=AD=E9=94=AE=E6=94=B9=E4=B8=BA?= =?UTF-8?q?=E5=85=A8=E5=B1=80=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/MaaWpfGui/Services/HotKeys/MaaHotKeyManager.cs | 4 ++-- .../Views/UserControl/HotKeySettingsUserControl.xaml | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/MaaWpfGui/Services/HotKeys/MaaHotKeyManager.cs b/src/MaaWpfGui/Services/HotKeys/MaaHotKeyManager.cs index 84ae3cc587..791487995a 100644 --- a/src/MaaWpfGui/Services/HotKeys/MaaHotKeyManager.cs +++ b/src/MaaWpfGui/Services/HotKeys/MaaHotKeyManager.cs @@ -115,7 +115,7 @@ namespace MaaWpfGui.Services.HotKeys private static Dictionary GetPersistentHotKeys() { - var hotKeysString = ConfigurationHelper.GetValue(HotKeyConfigName, null); + var hotKeysString = ConfigurationHelper.GetGlobalValue(HotKeyConfigName, null); return hotKeysString is null ? CreateInitialHotKeys() @@ -139,7 +139,7 @@ namespace MaaWpfGui.Services.HotKeys private void PersistHotKeys() { - ConfigurationHelper.SetValue(HotKeyConfigName, JsonConvert.SerializeObject(_actionHotKeyMapping)); + ConfigurationHelper.SetGlobalValue(HotKeyConfigName, JsonConvert.SerializeObject(_actionHotKeyMapping)); } } } diff --git a/src/MaaWpfGui/Views/UserControl/HotKeySettingsUserControl.xaml b/src/MaaWpfGui/Views/UserControl/HotKeySettingsUserControl.xaml index 81038a3099..131a52fcfd 100644 --- a/src/MaaWpfGui/Views/UserControl/HotKeySettingsUserControl.xaml +++ b/src/MaaWpfGui/Views/UserControl/HotKeySettingsUserControl.xaml @@ -21,6 +21,12 @@ Margin="10" HorizontalAlignment="Center" VerticalAlignment="Center"> +