mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Merge pull request #2137 from ngtr6788/search-plugin-store-refresh
Plugin Store search (should) work after refresh button clicked
This commit is contained in:
commit
c55edca7cc
1 changed files with 17 additions and 4 deletions
|
|
@ -9,6 +9,7 @@ using Flow.Launcher.ViewModel;
|
|||
using ModernWpf;
|
||||
using ModernWpf.Controls;
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Security.Policy;
|
||||
|
|
@ -58,12 +59,24 @@ namespace Flow.Launcher
|
|||
pluginListView = (CollectionView)CollectionViewSource.GetDefaultView(Plugins.ItemsSource);
|
||||
pluginListView.Filter = PluginListFilter;
|
||||
|
||||
pluginStoreView = (CollectionView)CollectionViewSource.GetDefaultView(StoreListBox.ItemsSource);
|
||||
pluginStoreView = (CollectionView)CollectionViewSource.GetDefaultView(StoreListBox.ItemsSource);
|
||||
pluginStoreView.Filter = PluginStoreFilter;
|
||||
|
||||
viewModel.PropertyChanged += new PropertyChangedEventHandler(SettingsWindowViewModelChanged);
|
||||
|
||||
InitializePosition();
|
||||
}
|
||||
|
||||
private void SettingsWindowViewModelChanged(object sender, PropertyChangedEventArgs e)
|
||||
{
|
||||
if (e.PropertyName == nameof(viewModel.ExternalPlugins))
|
||||
{
|
||||
pluginStoreView = (CollectionView)CollectionViewSource.GetDefaultView(StoreListBox.ItemsSource);
|
||||
pluginStoreView.Filter = PluginStoreFilter;
|
||||
pluginStoreView.Refresh();
|
||||
}
|
||||
}
|
||||
|
||||
private void OnSelectPythonPathClick(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var selectedFile = viewModel.GetFileFromDialog(
|
||||
|
|
@ -257,9 +270,9 @@ namespace Flow.Launcher
|
|||
{
|
||||
var confirmResult = MessageBox.Show(
|
||||
InternationalizationManager.Instance.GetTranslation("clearlogfolderMessage"),
|
||||
InternationalizationManager.Instance.GetTranslation("clearlogfolder"),
|
||||
InternationalizationManager.Instance.GetTranslation("clearlogfolder"),
|
||||
MessageBoxButton.YesNo);
|
||||
|
||||
|
||||
if (confirmResult == MessageBoxResult.Yes)
|
||||
{
|
||||
viewModel.ClearLogFolder();
|
||||
|
|
@ -390,7 +403,7 @@ namespace Flow.Launcher
|
|||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
private CollectionView pluginListView;
|
||||
private CollectionView pluginStoreView;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue