mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 04:34:59 +00:00
feature: added Ctrl+N/⌘+N
shortcut (#795)
(cherry picked from commit 726cf0d376a9af9167145560977ec6e1bf748277)
This commit is contained in:
parent
19307cebc0
commit
bea2a39feb
4 changed files with 24 additions and 3 deletions
|
@ -136,6 +136,22 @@ namespace SourceGit.Views
|
|||
return;
|
||||
}
|
||||
|
||||
if (e.Key == Key.N)
|
||||
{
|
||||
if (vm.ActivePage.Data is not ViewModels.Welcome)
|
||||
{
|
||||
vm.AddNewTab();
|
||||
}
|
||||
|
||||
if (vm.ActivePage.Data is ViewModels.Welcome welcome)
|
||||
{
|
||||
welcome.Clone();
|
||||
}
|
||||
|
||||
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))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue