Improve code quality

This commit is contained in:
Jack251970 2025-05-06 13:58:28 +08:00
parent 6799b87f96
commit b1a48e296a

View file

@ -35,7 +35,7 @@ namespace Flow.Launcher.ViewModel
private Query _lastQuery;
private bool _lastIsHomeQuery;
private string _queryTextBeforeLeaveResults;
private string _ignoredQueryText = null;
private string _ignoredQueryText; // Used to ignore query text change when switching between context menu and query results
private readonly FlowLauncherJsonStorage<History> _historyItemsStorage;
private readonly FlowLauncherJsonStorage<UserSelectedRecord> _userSelectedRecordStorage;
@ -67,6 +67,7 @@ namespace Flow.Launcher.ViewModel
_queryTextBeforeLeaveResults = "";
_queryText = "";
_lastQuery = new Query();
_ignoredQueryText = null; // null as invalid value
Settings = Ioc.Default.GetRequiredService<Settings>();
Settings.PropertyChanged += (_, args) =>