mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-01-18 22:43:31 +08:00
Disable forwarding the Escape event (#10697)
This commit is contained in:
parent
04101d23e7
commit
28e9f168d4
@ -54,7 +54,7 @@ namespace ColorPicker.Helpers
|
||||
}
|
||||
}
|
||||
|
||||
public void EndUserSession()
|
||||
public bool EndUserSession()
|
||||
{
|
||||
lock (_colorPickerVisibilityLock)
|
||||
{
|
||||
@ -70,7 +70,11 @@ namespace ColorPicker.Helpers
|
||||
}
|
||||
|
||||
SessionEventHelper.End();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -72,7 +72,7 @@ namespace ColorPicker.Keyboard
|
||||
// ESC pressed
|
||||
if (virtualCode == KeyInterop.VirtualKeyFromKey(Key.Escape))
|
||||
{
|
||||
_appStateHandler.EndUserSession();
|
||||
e.Handled = _appStateHandler.EndUserSession();
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user