Add BackToQueryResults api function back

This commit is contained in:
Jack251970 2025-02-22 19:44:21 +08:00
parent aee585620a
commit 6f55e8a35d
3 changed files with 9 additions and 1 deletions

View file

@ -305,6 +305,12 @@ namespace Flow.Launcher.Plugin
/// <param name="reselect">Choose the first result after reload if true; keep the last selected result if false. Default is true.</param>
public void ReQuery(bool reselect = true);
/// <summary>
/// Back to the query results.
/// This method should run when selected item is from context menu or history.
/// </summary>
public void BackToQueryResults();
/// <summary>
/// Displays a standardised Flow message box.
/// </summary>

View file

@ -319,6 +319,8 @@ namespace Flow.Launcher
public void ReQuery(bool reselect = true) => _mainVM.ReQuery(reselect);
public void BackToQueryResults() => _mainVM.BackToQueryResults();
public MessageBoxResult ShowMsgBox(string messageBoxText, string caption = "", MessageBoxButton button = MessageBoxButton.OK, MessageBoxImage icon = MessageBoxImage.None, MessageBoxResult defaultResult = MessageBoxResult.OK) =>
MessageBoxEx.Show(messageBoxText, caption, button, icon, defaultResult);

View file

@ -489,7 +489,7 @@ namespace Flow.Launcher.ViewModel
}
}
private void BackToQueryResults()
public void BackToQueryResults()
{
if (!SelectedIsFromQueryResults())
{