[PT Run] Fix some keyboard issues on plugin (#13490)

* Don't use enter for accelerator keys in results

Enter is already used to select commands in the context menu in the
result entries.

* Don't crash when trying to show a tooltip

* Clear hanging tooltips when keyboard navigating

* Starting/stopping service on Enter
This commit is contained in:
Jaime Bernardo
2021-09-28 15:30:44 +01:00
committed by GitHub
parent 7874b77104
commit c85fa98bcc
4 changed files with 54 additions and 16 deletions

View File

@@ -75,11 +75,12 @@ namespace Microsoft.PowerToys.Run.Plugin.Registry.Helper
list.Add(new ContextMenuResult
{
AcceleratorKey = Key.Enter,
AcceleratorModifiers = ModifierKeys.Control,
Action = _ => TryToOpenInRegistryEditor(entry),
FontFamily = "Segoe MDL2 Assets",
Glyph = "\xE8A7", // E8A7 => Symbol: OpenInNewWindow
PluginName = assemblyName,
Title = $"{Resources.OpenKeyInRegistryEditor} (Enter)",
Title = $"{Resources.OpenKeyInRegistryEditor} (Ctrl+Enter)",
});
return list;