mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
103 lines
No EOL
5.2 KiB
XML
103 lines
No EOL
5.2 KiB
XML
<UserControl
|
|
x:Class="Flow.Launcher.Plugin.BrowserBookmark.Views.SettingsControl"
|
|
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"
|
|
d:DesignHeight="300"
|
|
d:DesignWidth="500"
|
|
DataContext="{Binding RelativeSource={RelativeSource Self}}"
|
|
mc:Ignorable="d">
|
|
<Grid Margin="{StaticResource SettingPanelMargin}">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
<StackPanel
|
|
Grid.Row="0"
|
|
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
|
Orientation="Horizontal">
|
|
<TextBlock
|
|
Margin="{StaticResource SettingPanelItemRightMargin}"
|
|
VerticalAlignment="Center"
|
|
Text="{DynamicResource flowlauncher_plugin_browserbookmark_loadBrowserFrom}" />
|
|
<CheckBox
|
|
Margin="{StaticResource SettingPanelItemRightMargin}"
|
|
Content="Chrome"
|
|
IsChecked="{Binding LoadChromeBookmark}" />
|
|
<CheckBox
|
|
Margin="{StaticResource SettingPanelItemRightMargin}"
|
|
Content="Edge"
|
|
IsChecked="{Binding LoadEdgeBookmark}" />
|
|
<CheckBox
|
|
Margin="{StaticResource SettingPanelItemRightMargin}"
|
|
Content="Firefox"
|
|
IsChecked="{Binding LoadFirefoxBookmark}" />
|
|
<Button
|
|
Margin="{StaticResource SettingPanelItemRightMargin}"
|
|
Click="Others_Click"
|
|
Content="{DynamicResource flowlauncher_plugin_browserbookmark_others}" />
|
|
</StackPanel>
|
|
<StackPanel
|
|
Name="CustomBrowsersList"
|
|
Grid.Row="1"
|
|
Visibility="Collapsed">
|
|
<ListView
|
|
Name="CustomBrowsers"
|
|
Height="auto"
|
|
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
|
BorderBrush="DarkGray"
|
|
BorderThickness="1"
|
|
ItemsSource="{Binding Settings.CustomChromiumBrowsers}"
|
|
MouseDoubleClick="MouseDoubleClickOnSelectedCustomBrowser"
|
|
SelectedItem="{Binding SelectedCustomBrowser}"
|
|
Style="{StaticResource {x:Static GridView.GridViewStyleKey}}">
|
|
<ListView.View>
|
|
<GridView>
|
|
<GridViewColumn DisplayMemberBinding="{Binding Name, Mode=OneWay}" Header="{DynamicResource flowlauncher_plugin_browserbookmark_browserName}" />
|
|
<GridViewColumn DisplayMemberBinding="{Binding DataDirectoryPath, Mode=OneWay}" Header="{DynamicResource flowlauncher_plugin_browserbookmark_browserBookmarkDataDirectory}" />
|
|
<GridViewColumn DisplayMemberBinding="{Binding BrowserType, Mode=OneWay}" Header="{DynamicResource flowlauncher_plugin_browserbookmark_browserEngine}" />
|
|
</GridView>
|
|
</ListView.View>
|
|
</ListView>
|
|
<StackPanel
|
|
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
|
HorizontalAlignment="Right"
|
|
Orientation="Horizontal">
|
|
<Button
|
|
Width="100"
|
|
Click="NewCustomBrowser"
|
|
Content="{DynamicResource flowlauncher_plugin_browserbookmark_addBrowserBookmark}" />
|
|
<Button
|
|
Width="100"
|
|
Margin="{StaticResource SettingPanelItemLeftMargin}"
|
|
Click="EditCustomBrowser"
|
|
Content="{DynamicResource flowlauncher_plugin_browserbookmark_editBrowserBookmark}">
|
|
<Button.Style>
|
|
<Style BasedOn="{StaticResource DefaultButtonStyle}" TargetType="Button">
|
|
<Setter Property="IsEnabled" Value="true" />
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding ElementName=CustomBrowsers, Path=SelectedItems.Count}" Value="0">
|
|
<Setter Property="IsEnabled" Value="false" />
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</Button.Style>
|
|
</Button>
|
|
<Button
|
|
Width="100"
|
|
Margin="{StaticResource SettingPanelItemLeftMargin}"
|
|
Click="DeleteCustomBrowser"
|
|
Content="{DynamicResource flowlauncher_plugin_browserbookmark_removeBrowserBookmark}" />
|
|
</StackPanel>
|
|
</StackPanel>
|
|
<CheckBox
|
|
Grid.Row="2"
|
|
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
|
HorizontalAlignment="Left"
|
|
VerticalAlignment="Center"
|
|
Content="{DynamicResource flowlauncher_plugin_browserbookmark_enable_favicons}"
|
|
IsChecked="{Binding Settings.EnableFavicons}" />
|
|
</Grid>
|
|
</UserControl> |