mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 19:57:57 +01:00
implemented ctrl + w to close peek. (#29895)
* ctrl + w to close peek * Update MainWindow.xaml * Update MainWindow.xaml.cs * Update MainWindow.xaml * Update MainWindow.xaml CloseInvoked * Update MainWindow.xaml.cs EscInvoked -> CloseInvoked * Update MainWindow.xaml.cs XAML Styler extension
This commit is contained in:
@@ -22,7 +22,11 @@
|
|||||||
<KeyboardAccelerator Key="Up" Invoked="PreviousNavigationInvoked" />
|
<KeyboardAccelerator Key="Up" Invoked="PreviousNavigationInvoked" />
|
||||||
<KeyboardAccelerator Key="Right" Invoked="NextNavigationInvoked" />
|
<KeyboardAccelerator Key="Right" Invoked="NextNavigationInvoked" />
|
||||||
<KeyboardAccelerator Key="Down" Invoked="NextNavigationInvoked" />
|
<KeyboardAccelerator Key="Down" Invoked="NextNavigationInvoked" />
|
||||||
<KeyboardAccelerator Key="Escape" Invoked="EscKeyInvoked" />
|
<KeyboardAccelerator Key="Escape" Invoked="CloseInvoked" />
|
||||||
|
<KeyboardAccelerator
|
||||||
|
Key="W"
|
||||||
|
Invoked="CloseInvoked"
|
||||||
|
Modifiers="Control" />
|
||||||
</Grid.KeyboardAccelerators>
|
</Grid.KeyboardAccelerators>
|
||||||
|
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ namespace Peek.UI
|
|||||||
ViewModel.AttemptNextNavigation();
|
ViewModel.AttemptNextNavigation();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void EscKeyInvoked(KeyboardAccelerator sender, KeyboardAcceleratorInvokedEventArgs args)
|
private void CloseInvoked(KeyboardAccelerator sender, KeyboardAcceleratorInvokedEventArgs args)
|
||||||
{
|
{
|
||||||
Uninitialize();
|
Uninitialize();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user