diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/ViewModels/SettingsViewModel.cs b/Plugins/Flow.Launcher.Plugin.Explorer/ViewModels/SettingsViewModel.cs index efffb19e0..171b5ce00 100644 --- a/Plugins/Flow.Launcher.Plugin.Explorer/ViewModels/SettingsViewModel.cs +++ b/Plugins/Flow.Launcher.Plugin.Explorer/ViewModels/SettingsViewModel.cs @@ -35,7 +35,6 @@ namespace Flow.Launcher.Plugin.Explorer.ViewModels InitializeEngineSelection(); InitializeActionKeywordModels(); - EverythingSortOptionLocalized.UpdateLabels(AllEverythingSortOptions); } public void Save() @@ -579,7 +578,19 @@ namespace Flow.Launcher.Plugin.Explorer.ViewModels #region Everything FastSortWarning - public List AllEverythingSortOptions { get; } = EverythingSortOptionLocalized.GetValues(); + private List _allEverythingSortOptions = new(); + public List AllEverythingSortOptions + { + get + { + if (_allEverythingSortOptions.Count == 0) + { + _allEverythingSortOptions = EverythingSortOptionLocalized.GetValues(); + EverythingSortOptionLocalized.UpdateLabels(_allEverythingSortOptions); + } + return _allEverythingSortOptions; + } + } public EverythingSortOption SelectedEverythingSortOption { diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml.cs b/Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml.cs index ddbaa7d70..38928ff03 100644 --- a/Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml.cs +++ b/Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml.cs @@ -39,8 +39,6 @@ namespace Flow.Launcher.Plugin.Explorer.Views ExcludedPathsExpander }; - // Update labels because the view model is initialized in InitAsync - Search.Everything.EverythingSortOptionLocalized.UpdateLabels(_viewModel.AllEverythingSortOptions); } private void AccessLinkDragDrop(string containerName, DragEventArgs e)