Skip to content

Commit 35bad61

Browse files
committed
Add file exclude related settings
1 parent 08af45f commit 35bad61

File tree

3 files changed

+28
-0
lines changed

3 files changed

+28
-0
lines changed

Plugins/Flow.Launcher.Plugin.Explorer/Settings.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ public class Settings
2525

2626
public string ShellPath { get; set; } = "cmd";
2727

28+
public string ExcludedFileTypes { get; set; } = "";
29+
2830

2931
public bool UseLocationAsWorkingDir { get; set; } = false;
3032

Plugins/Flow.Launcher.Plugin.Explorer/ViewModels/SettingsViewModel.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -513,6 +513,17 @@ public string ShellPath
513513
}
514514
}
515515

516+
public string ExcludedFileTypes
517+
{
518+
get => Settings.ExcludedFileTypes;
519+
set
520+
{
521+
string sanitized = string.IsNullOrEmpty(value) ? value : value.Replace(" ", "").Replace(".", "");
522+
Settings.ExcludedFileTypes = sanitized;
523+
OnPropertyChanged();
524+
}
525+
}
526+
516527

517528
#region Everything FastSortWarning
518529

Plugins/Flow.Launcher.Plugin.Explorer/Views/ExplorerSettings.xaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,7 @@
281281
<RowDefinition />
282282
<RowDefinition />
283283
<RowDefinition />
284+
<RowDefinition />
284285
</Grid.RowDefinitions>
285286
<TextBlock
286287
Grid.Row="0"
@@ -333,6 +334,20 @@
333334
DisplayMemberPath="Description"
334335
ItemsSource="{Binding PathEnumerationEngines}"
335336
SelectedItem="{Binding SelectedPathEnumerationEngine}" />
337+
<TextBlock
338+
Grid.Row="3"
339+
Grid.Column="0"
340+
Margin="0 15 20 0"
341+
VerticalAlignment="Center"
342+
Text="{DynamicResource plugin_explorer_Excluded_File_Types}"
343+
TextBlock.Foreground="{DynamicResource Color05B}" />
344+
<TextBox
345+
Grid.Row="3"
346+
Grid.Column="1"
347+
MinWidth="350"
348+
Margin="0,9,0,6"
349+
ToolTip="{DynamicResource plugin_explorer_Excluded_File_Types_Tooltip}"
350+
Text="{Binding ExcludedFileTypes}" />
336351
</Grid>
337352
</StackPanel>
338353
<StackPanel Orientation="Horizontal">

0 commit comments

Comments
 (0)