diff --git a/src/Views/Launcher.axaml.cs b/src/Views/Launcher.axaml.cs index b5f09d79..e3140191 100644 --- a/src/Views/Launcher.axaml.cs +++ b/src/Views/Launcher.axaml.cs @@ -120,6 +120,13 @@ namespace SourceGit.Views return; } + // Ctrl+Q quits the application (macOS use hotkeys in system menu bar) + if (!OperatingSystem.IsMacOS() && e.KeyModifiers == KeyModifiers.Control && e.Key == Key.Q) + { + App.Quit(0); + return; + } + if (e.KeyModifiers.HasFlag(OperatingSystem.IsMacOS() ? KeyModifiers.Meta : KeyModifiers.Control)) { if (e.Key == Key.W) @@ -146,13 +153,6 @@ namespace SourceGit.Views return; } - if (e.Key == Key.Q) - { - App.Quit(0); - e.Handled = true; - return; - } - if ((OperatingSystem.IsMacOS() && e.KeyModifiers.HasFlag(KeyModifiers.Alt) && e.Key == Key.Right) || (!OperatingSystem.IsMacOS() && !e.KeyModifiers.HasFlag(KeyModifiers.Shift) && e.Key == Key.Tab)) {