From 2ecad2fea2ca4727838c85a0798e29af15f26ea0 Mon Sep 17 00:00:00 2001 From: liufei Date: Fri, 3 Jun 2022 23:53:03 +0800 Subject: [PATCH] =?UTF-8?q?:bug:=E4=BF=AE=E5=A4=8DF1--F12=E5=BF=AB?= =?UTF-8?q?=E6=8D=B7=E9=94=AE=E4=B8=8D=E6=98=BE=E7=A4=BA=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Control/UserControls/Config/MotionControl.xaml.cs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/Control/UserControls/Config/MotionControl.xaml.cs b/Control/UserControls/Config/MotionControl.xaml.cs index 944ff11..ce775ac 100644 --- a/Control/UserControls/Config/MotionControl.xaml.cs +++ b/Control/UserControls/Config/MotionControl.xaml.cs @@ -35,8 +35,6 @@ namespace GeekDesk.Control.UserControls.Config /// private void HotKeyDown(object sender, KeyEventArgs e) { - Console.WriteLine("downKey:" + e.Key.ToString()); - lock (this) { HotKeyType hkType = (HotKeyType)(sender as TextBox).Tag; @@ -49,8 +47,6 @@ namespace GeekDesk.Control.UserControls.Config if (!CheckIsEnable(hkType)) return; - - Console.WriteLine("prevKeyTemp:" + prevKeyTemp.ToString()); if (prevKeyTemp == Key.None || prevKeyTemp != downKey) { @@ -101,7 +97,6 @@ namespace GeekDesk.Control.UserControls.Config appConfig.ColorPickerHotkeyModifiers = GetModifierKeys(downKey); break; } - Console.WriteLine("进入设置" + downKey.ToString()); prevKeyTemp = downKey; keysTemp.Add(e); } @@ -119,7 +114,10 @@ namespace GeekDesk.Control.UserControls.Config KeyUtil.KeyProp keyProp = new KeyUtil.KeyProp(); KeyUtil.KeyToChar(downKey, ref keyProp, true); string downKeyStr = keyProp.character.ToString(); - //string downKeyStr = ""; + if (keyProp.character == '\x00') + { + downKeyStr = downKey.ToString(); + } switch (hkType) { case HotKeyType.Main: