mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Initial Tab complete
This commit is contained in:
parent
96bcf1b1f0
commit
5a733d05db
2 changed files with 18 additions and 1 deletions
|
|
@ -41,7 +41,7 @@
|
||||||
<KeyBinding Key="Escape" Command="{Binding EscCommand}" />
|
<KeyBinding Key="Escape" Command="{Binding EscCommand}" />
|
||||||
<KeyBinding Key="F1" Command="{Binding StartHelpCommand}" />
|
<KeyBinding Key="F1" Command="{Binding StartHelpCommand}" />
|
||||||
<KeyBinding Key="F5" Command="{Binding ReloadPluginDataCommand}" />
|
<KeyBinding Key="F5" Command="{Binding ReloadPluginDataCommand}" />
|
||||||
<KeyBinding Key="Tab" Command="{Binding SelectNextItemCommand}" />
|
<KeyBinding Key="Tab" Command="{Binding ReplaceQueryWithResult}" />
|
||||||
<KeyBinding
|
<KeyBinding
|
||||||
Key="Tab"
|
Key="Tab"
|
||||||
Command="{Binding SelectPrevItemCommand}"
|
Command="{Binding SelectPrevItemCommand}"
|
||||||
|
|
|
||||||
|
|
@ -228,6 +228,22 @@ namespace Flow.Launcher.ViewModel
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
ReplaceQueryWithResult = new RelayCommand(index =>
|
||||||
|
{
|
||||||
|
var results = SelectedResults;
|
||||||
|
|
||||||
|
if (index != null)
|
||||||
|
{
|
||||||
|
results.SelectedIndex = int.Parse(index.ToString());
|
||||||
|
}
|
||||||
|
|
||||||
|
var result = results.SelectedItem?.Result;
|
||||||
|
if (result != null) // SelectedItem returns null if selection is empty.
|
||||||
|
{
|
||||||
|
ChangeQueryText(result.Title, true);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
LoadContextMenuCommand = new RelayCommand(_ =>
|
LoadContextMenuCommand = new RelayCommand(_ =>
|
||||||
{
|
{
|
||||||
if (SelectedIsFromQueryResults())
|
if (SelectedIsFromQueryResults())
|
||||||
|
|
@ -383,6 +399,7 @@ namespace Flow.Launcher.ViewModel
|
||||||
public ICommand OpenSettingCommand { get; set; }
|
public ICommand OpenSettingCommand { get; set; }
|
||||||
public ICommand ReloadPluginDataCommand { get; set; }
|
public ICommand ReloadPluginDataCommand { get; set; }
|
||||||
public ICommand ClearQueryCommand { get; private set; }
|
public ICommand ClearQueryCommand { get; private set; }
|
||||||
|
public ICommand ReplaceQueryWithResult { get; set; }
|
||||||
|
|
||||||
public string OpenResultCommandModifiers { get; private set; }
|
public string OpenResultCommandModifiers { get; private set; }
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue