mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
fix: lost focus change current hotkey before stop recording store that
This commit is contained in:
parent
b7ccab67d1
commit
c39da2f5f3
1 changed files with 2 additions and 3 deletions
|
|
@ -116,6 +116,8 @@ namespace Flow.Launcher.ViewModel
|
|||
SetKeysToDisplay(KeysToDisplay, CurrentHotkey);
|
||||
return;
|
||||
}
|
||||
|
||||
Hotkey = CurrentHotkey.ToString();
|
||||
|
||||
await SetHotkeyAsync(CurrentHotkey, true);
|
||||
}
|
||||
|
|
@ -146,20 +148,17 @@ namespace Flow.Launcher.ViewModel
|
|||
if (triggerValidate)
|
||||
{
|
||||
bool hotkeyAvailable = CheckHotkeyAvailability(keyModel, ValidateKeyGesture);
|
||||
CurrentHotkeyAvailable = hotkeyAvailable;
|
||||
SetMessage(hotkeyAvailable ? "success" : "hotkeyUnavailable", !hotkeyAvailable);
|
||||
HotkeyDelegate?.Invoke(keyModel);
|
||||
|
||||
if (CurrentHotkeyAvailable)
|
||||
{
|
||||
CurrentHotkey = keyModel;
|
||||
Hotkey = keyModel.ToString();
|
||||
SetKeysToDisplay(KeysToDisplay, CurrentHotkey);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
CurrentHotkey = keyModel;
|
||||
Hotkey = keyModel.ToString();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue