mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
177 lines
No EOL
9.2 KiB
XML
177 lines
No EOL
9.2 KiB
XML
<UserControl
|
|
x:Class="Flow.Launcher.Plugin.Explorer.Views.ExplorerSettings"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:qa="clr-namespace:Flow.Launcher.Plugin.Explorer.Search.QuickAccessLinks"
|
|
xmlns:viewModels="clr-namespace:Flow.Launcher.Plugin.Explorer.ViewModels"
|
|
xmlns:views="clr-namespace:Flow.Launcher.Plugin.Explorer.Views"
|
|
d:DataContext="{d:DesignInstance viewModels:SettingsViewModel}"
|
|
d:DesignHeight="450"
|
|
d:DesignWidth="800"
|
|
mc:Ignorable="d">
|
|
<UserControl.Resources>
|
|
<DataTemplate x:Key="ListViewTemplateAccessLinks" DataType="qa:AccessLink">
|
|
<TextBlock Margin="0,5,0,5" Text="{Binding Path, Mode=OneTime}" />
|
|
</DataTemplate>
|
|
<DataTemplate x:Key="ListViewActionKeywords" DataType="views:ActionKeywordView">
|
|
<Grid>
|
|
<TextBlock
|
|
Margin="0,5,0,0"
|
|
IsEnabled="{Binding Enabled}"
|
|
Text="{Binding Description, Mode=OneTime}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="{x:Type TextBlock}">
|
|
<Style.Triggers>
|
|
<Trigger Property="IsEnabled" Value="True">
|
|
<Setter Property="Foreground" Value="{DynamicResource Color05B}" />
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter Property="Foreground" Value="{DynamicResource Color18B}" />
|
|
</Trigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Margin="250,5,0,0"
|
|
IsEnabled="{Binding Enabled}"
|
|
Text="{Binding Keyword}">
|
|
<TextBlock.Style>
|
|
<Style TargetType="{x:Type TextBlock}">
|
|
<Style.Triggers>
|
|
<Trigger Property="IsEnabled" Value="True">
|
|
<Setter Property="Foreground" Value="{DynamicResource Color05B}" />
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled" Value="False">
|
|
<Setter Property="Foreground" Value="{DynamicResource Color18B}" />
|
|
</Trigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</TextBlock.Style>
|
|
</TextBlock>
|
|
</Grid>
|
|
</DataTemplate>
|
|
</UserControl.Resources>
|
|
<Grid Margin="10">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="*" />
|
|
<RowDefinition Height="100" />
|
|
</Grid.RowDefinitions>
|
|
<StackPanel Grid.Row="0" Margin="20,35,0,0">
|
|
<StackPanel>
|
|
<Expander
|
|
Header="{DynamicResource plugin_explorer_generalsetting_header}">
|
|
<StackPanel Orientation="Vertical">
|
|
<CheckBox
|
|
Name="UseWindowsIndexForDirectorySearch"
|
|
Margin="12,10,0,0"
|
|
Content="{DynamicResource plugin_explorer_usewindowsindexfordirectorysearch}"
|
|
IsChecked="{Binding UseWindowsIndexForDirectorySearch}"
|
|
ToolTip="{DynamicResource plugin_explorer_usewindowsindexfordirectorysearch_tooltip}" />
|
|
<ComboBox
|
|
Width="200"
|
|
ItemsSource="{Binding Settings.SortOptions, Mode=OneWay}"
|
|
SelectedItem="{Binding Settings.SortOption}" />
|
|
</StackPanel>
|
|
</Expander>
|
|
<Expander
|
|
Name="expActionKeywords"
|
|
Height="auto"
|
|
Expanded="expActionKeywords_Click"
|
|
Header="{DynamicResource plugin_explorer_manageactionkeywords_header}">
|
|
<DockPanel HorizontalAlignment="Stretch">
|
|
<ListView
|
|
x:Name="lbxActionKeywords"
|
|
DockPanel.Dock="Top"
|
|
ItemTemplate="{StaticResource ListViewActionKeywords}"
|
|
SelectedItem="{Binding SelectedActionKeyword}"/>
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding EditActionKeywordCommand}"
|
|
Content="{DynamicResource plugin_explorer_edit}" />
|
|
</DockPanel>
|
|
</Expander>
|
|
<Expander
|
|
Name="expAccessLinks"
|
|
Margin="0,10,0,0"
|
|
Header="{DynamicResource plugin_explorer_quickaccesslinks_header}">
|
|
<DockPanel HorizontalAlignment="Stretch">
|
|
<ListView
|
|
x:Name="lbxAccessLinks"
|
|
Height="200"
|
|
AllowDrop="True"
|
|
DockPanel.Dock="Top"
|
|
ItemTemplate="{StaticResource ListViewTemplateAccessLinks}"
|
|
ItemsSource="{Binding Settings.QuickAccessLinks}"
|
|
SelectedItem="{Binding SelectedQuickAccessLink}" />
|
|
<StackPanel
|
|
HorizontalAlignment="Right"
|
|
DockPanel.Dock="Bottom"
|
|
Orientation="Horizontal">
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding RemoveLinkCommand}"
|
|
CommandParameter="QuickAccessLink"
|
|
Content="{DynamicResource plugin_explorer_delete}" />
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding EditLinkCommand}"
|
|
CommandParameter="QuickAccessLink"
|
|
Content="{DynamicResource plugin_explorer_edit}" />
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding AddLinkCommand}"
|
|
CommandParameter="QuickAccessLink"
|
|
Content="{DynamicResource plugin_explorer_add}" />
|
|
</StackPanel>
|
|
</DockPanel>
|
|
</Expander>
|
|
<Expander
|
|
x:Name="expExcludedPaths"
|
|
Margin="0,10,0,0"
|
|
Header="{DynamicResource plugin_explorer_indexsearchexcludedpaths_header}">
|
|
<DockPanel HorizontalAlignment="Stretch">
|
|
<ListView
|
|
Name="lbxExcludedPaths"
|
|
AllowDrop="True"
|
|
DockPanel.Dock="Top"
|
|
DragEnter="lbxAccessLinks_DragEnter"
|
|
Drop="lbxAccessLinks_Drop"
|
|
ItemTemplate="{StaticResource ListViewActionKeywords}"
|
|
ItemsSource="{Binding Settings.IndexSearchExcludedSubdirectoryPaths}"
|
|
SelectedItem="{Binding SelectedIndexSearchExcludedPath}" />
|
|
<StackPanel
|
|
HorizontalAlignment="Right"
|
|
DockPanel.Dock="Bottom"
|
|
Orientation="Horizontal">
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding RemoveLinkCommand}"
|
|
CommandParameter="IndexSearchExcludedPaths"
|
|
Content="{DynamicResource plugin_explorer_delete}" />
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding EditLinkCommand}"
|
|
CommandParameter="IndexSearchExcludedPaths"
|
|
Content="{DynamicResource plugin_explorer_edit}" />
|
|
<Button
|
|
MinWidth="100"
|
|
Margin="10"
|
|
Command="{Binding AddLinkCommand}"
|
|
CommandParameter="IndexSearchExcludedPaths"
|
|
Content="{DynamicResource plugin_explorer_add}" />
|
|
</StackPanel>
|
|
</DockPanel>
|
|
</Expander>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</Grid>
|
|
</UserControl> |