Add file exclude related settings

This commit is contained in:
Lasith Manujitha 2024-07-17 04:14:18 +05:30
parent 08af45fd3c
commit 35bad615f3
3 changed files with 28 additions and 0 deletions

View file

@ -25,6 +25,8 @@ namespace Flow.Launcher.Plugin.Explorer
public string ShellPath { get; set; } = "cmd";
public string ExcludedFileTypes { get; set; } = "";
public bool UseLocationAsWorkingDir { get; set; } = false;

View file

@ -513,6 +513,17 @@ namespace Flow.Launcher.Plugin.Explorer.ViewModels
}
}
public string ExcludedFileTypes
{
get => Settings.ExcludedFileTypes;
set
{
string sanitized = string.IsNullOrEmpty(value) ? value : value.Replace(" ", "").Replace(".", "");
Settings.ExcludedFileTypes = sanitized;
OnPropertyChanged();
}
}
#region Everything FastSortWarning

View file

@ -281,6 +281,7 @@
<RowDefinition />
<RowDefinition />
<RowDefinition />
<RowDefinition />
</Grid.RowDefinitions>
<TextBlock
Grid.Row="0"
@ -333,6 +334,20 @@
DisplayMemberPath="Description"
ItemsSource="{Binding PathEnumerationEngines}"
SelectedItem="{Binding SelectedPathEnumerationEngine}" />
<TextBlock
Grid.Row="3"
Grid.Column="0"
Margin="0 15 20 0"
VerticalAlignment="Center"
Text="{DynamicResource plugin_explorer_Excluded_File_Types}"
TextBlock.Foreground="{DynamicResource Color05B}" />
<TextBox
Grid.Row="3"
Grid.Column="1"
MinWidth="350"
Margin="0,9,0,6"
ToolTip="{DynamicResource plugin_explorer_Excluded_File_Types_Tooltip}"
Text="{Binding ExcludedFileTypes}" />
</Grid>
</StackPanel>
<StackPanel Orientation="Horizontal">