fix erros

This commit is contained in:
01Dri 2025-10-11 03:23:14 -03:00
parent e468c48da4
commit d7579cce9e
2 changed files with 6 additions and 10 deletions

View file

@ -16,14 +16,14 @@ namespace Flow.Launcher.Storage
private int _maxHistory = 300;
public void AddToHistory(Result result, bool isQuery)
public void AddToHistory(Result result, Settings settings)
{
if (isQuery)
{
AddLastQuery(result);
if (!settings.ShowHistoryOnHomePage) return;
if (settings.ShowHistoryQueryResultsForHomePage)
{
AddLastQuery(result);
return;
}
AddLastOpened(result);
}

View file

@ -536,11 +536,7 @@ namespace Flow.Launcher.ViewModel
if (QueryResultsSelected())
{
if (Settings.ShowHistoryOnHomePage)
{
_history.AddToHistory(result, Settings.ShowHistoryQueryResultsForHomePage);
}
_history.AddToHistory(result, Settings);
_userSelectedRecord.Add(result);
lastHistoryIndex = 1;
}