Skip to content
This repository was archived by the owner on Jul 18, 2023. It is now read-only.

Commit b68eda0

Browse files
committed
Remove obsolete component
1 parent ab3019a commit b68eda0

4 files changed

Lines changed: 12 additions & 33 deletions

File tree

EverythingSettings.xaml

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
55
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
66
xmlns:helper="clr-namespace:Flow.Launcher.Plugin.Everything.Helper"
7+
xmlns:vm="clr-namespace:Flow.Launcher.Plugin.Everything.ViewModels"
78
mc:Ignorable="d"
89
Loaded="View_Loaded"
910
d:DesignHeight="300" d:DesignWidth="426.4">
@@ -13,7 +14,6 @@
1314
<RowDefinition/>
1415
<RowDefinition/>
1516
<RowDefinition Height="50"/>
16-
<RowDefinition Height="50"/>
1717
</Grid.RowDefinitions>
1818
<Grid.ColumnDefinitions>
1919
<ColumnDefinition />
@@ -34,31 +34,15 @@
3434
<Label Grid.Row="2" Grid.Column="1" x:Name="EditorPath" Margin="10" HorizontalAlignment="Left" />
3535
<Button Grid.Row="2" Grid.Column="2" x:Name="OpenEditorPath" Content="..." Margin="10"
3636
HorizontalAlignment="Left" Click="EditorPath_Clicked"/>
37-
<TextBlock Grid.Row="3" Text="{DynamicResource flowlauncher_plugin_everything_customized_title}" Margin="10,0,0,0" VerticalAlignment="Center"
38-
ToolTip="{DynamicResource flowlauncher_plugin_everything_customized_tooltip}"/>
39-
<TextBox Grid.Row="3"
40-
Grid.Column="1"
41-
TextWrapping="NoWrap"
42-
VerticalAlignment="Center"
43-
HorizontalAlignment="Left"
44-
Width="150"
45-
Height="35"
46-
Margin="0,5,0,0"
47-
TextChanged="CustomizeExplorer" x:Name="CustomizeExplorerBox"/>
48-
<TextBlock Grid.Row="3" Grid.Column="2" Text="{DynamicResource flowlauncher_plugin_everything_customized_args}" VerticalAlignment="Center" Margin="5"
49-
ToolTip="{DynamicResource flowlauncher_plugin_everything_customized_args_tooltip}"></TextBlock>
50-
<TextBox Grid.Row="3" Grid.Column="2" HorizontalAlignment="Right"
51-
ToolTip="{DynamicResource flowlauncher_plugin_everything_customized_args_textbox}"
52-
Margin="0,0,5,0" Width="80" Height="35" x:Name="CustomizeArgsBox" TextChanged="CustomizeExplorerArgs"></TextBox>
53-
<TextBlock Margin="10 15 10 10" Text="{DynamicResource flowlauncher_plugin_everything_sort_by}" Grid.Row="4"/>
37+
<TextBlock Margin="10 15 10 10" Text="{DynamicResource flowlauncher_plugin_everything_sort_by}" Grid.Row="3"/>
5438

55-
<ComboBox Grid.Row="4"
39+
<ComboBox Grid.Row="3"
5640
Grid.Column="1"
5741
Width="200"
5842
Margin="0 10 0 0"
5943
SelectedItem="{Binding SortOption}"
6044
ItemsSource="{Binding GetSortOptions, Mode=OneWay}"
61-
SelectionChanged="onSelectionChange">
45+
SelectionChanged="onSelectionChange" d:DataContext="{d:DesignInstance vm:SettingsViewModel}">
6246
<ComboBox.ItemTemplate>
6347
<DataTemplate>
6448
<Grid>

EverythingSettings.xaml.cs

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ private void View_Loaded(object sender, RoutedEventArgs re)
4646
};
4747

4848
EditorPath.Content = settings.EditorPath;
49-
CustomizeExplorerBox.Text = settings.ExplorerPath;
50-
CustomizeArgsBox.Text = settings.ExplorerArgs;
5149
}
5250

5351
private void EditorPath_Clicked(object sender, RoutedEventArgs e)
@@ -65,15 +63,6 @@ private void EditorPath_Clicked(object sender, RoutedEventArgs e)
6563
EditorPath.Content = settings.EditorPath;
6664
}
6765

68-
private void CustomizeExplorer(object sender, TextChangedEventArgs e)
69-
{
70-
settings.ExplorerPath = CustomizeExplorerBox.Text;
71-
}
72-
73-
private void CustomizeExplorerArgs(object sender, TextChangedEventArgs e)
74-
{
75-
settings.ExplorerArgs = CustomizeArgsBox.Text;
76-
}
7766

7867
private void onSelectionChange(object sender, SelectionChangedEventArgs e)
7968
{

Helper/EnumNameConverter.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ namespace Flow.Launcher.Plugin.Everything.Helper
1111
{
1212
class EnumNameConverter : IValueConverter
1313
{
14-
private Dictionary<string, SortOption> translationRecord = new Dictionary<string, SortOption>();
15-
1614
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
1715
{
1816
return value is SortOption option ? option.GetTranslatedName() : value;

Settings.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,16 @@ public class Settings
1111

1212
public string EditorPath { get; set; } = "";
1313

14+
[Obsolete]
1415
internal const string Explorer = "explorer";
1516

17+
[Obsolete]
1618
internal const string alternativeExplorerPath = "explorer.exe";
1719

20+
[Obsolete]
1821
internal string explorerPath = Explorer;
1922

23+
[Obsolete]
2024
public string ExplorerPath
2125
{
2226
get => explorerPath.Trim() switch
@@ -26,12 +30,16 @@ public string ExplorerPath
2630
_ => explorerPath
2731
}; set => explorerPath = value;
2832
}
33+
[Obsolete]
2934
public string ExplorerArgs { get; set; } = DirectoryPathPlaceHolder;
3035

36+
[Obsolete]
3137
internal const string DirectoryPathPlaceHolder = "%s";
3238

39+
[Obsolete]
3340
internal const string FilePathPlaceHolder = "%f";
3441

42+
[Obsolete]
3543
internal const string DefaultExplorerArgsWithFilePath = "/select, %f";
3644

3745
public List<ContextMenu> ContextMenus = new List<ContextMenu>();

0 commit comments

Comments
 (0)