|
| 1 | +<UserControl |
| 2 | + x:Class="Flow.Launcher.Plugin.Url.SettingsControl" |
| 3 | + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
| 4 | + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| 5 | + xmlns:converters="clr-namespace:Flow.Launcher.Plugin.Url.Converters" |
| 6 | + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
| 7 | + xmlns:local="clr-namespace:Flow.Launcher.Plugin.Url" |
| 8 | + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
| 9 | + d:DesignHeight="450" |
| 10 | + d:DesignWidth="800" |
| 11 | + DataContext="{Binding RelativeSource={RelativeSource Self}}" |
| 12 | + mc:Ignorable="d"> |
| 13 | + <UserControl.Resources> |
| 14 | + <converters:InverseBoolConverter x:Key="InverseBoolConverter" /> |
| 15 | + <converters:BoolToVisibilityConverter x:Key="BoolToVisibilityConverter" /> |
| 16 | + </UserControl.Resources> |
| 17 | + |
| 18 | + <Grid Margin="{StaticResource SettingPanelMargin}"> |
| 19 | + <Grid.RowDefinitions> |
| 20 | + <RowDefinition Height="auto" /> |
| 21 | + <RowDefinition Height="auto" /> |
| 22 | + </Grid.RowDefinitions> |
| 23 | + |
| 24 | + <CheckBox |
| 25 | + Grid.Row="0" |
| 26 | + Margin="{StaticResource SettingPanelItemTopBottomMargin}" |
| 27 | + HorizontalAlignment="Left" |
| 28 | + VerticalAlignment="Center" |
| 29 | + Content="{DynamicResource flowlauncher_plugin_url_use_custom_browser}" |
| 30 | + IsChecked="{Binding Settings.UseCustomBrowser, Mode=TwoWay}" /> |
| 31 | + |
| 32 | + <Grid |
| 33 | + Grid.Row="1" |
| 34 | + HorizontalAlignment="Left" |
| 35 | + Visibility="{Binding Settings.UseCustomBrowser, Converter={StaticResource BoolToVisibilityConverter}, Mode=OneWay}"> |
| 36 | + <Grid.RowDefinitions> |
| 37 | + <RowDefinition Height="auto" /> |
| 38 | + <RowDefinition Height="auto" /> |
| 39 | + <RowDefinition Height="auto" /> |
| 40 | + </Grid.RowDefinitions> |
| 41 | + <Grid.ColumnDefinitions> |
| 42 | + <ColumnDefinition Width="Auto" /> |
| 43 | + <ColumnDefinition Width="*" /> |
| 44 | + </Grid.ColumnDefinitions> |
| 45 | + |
| 46 | + <TextBlock |
| 47 | + Grid.Row="0" |
| 48 | + Grid.Column="0" |
| 49 | + Margin="{StaticResource SettingPanelItemRightTopBottomMargin}" |
| 50 | + VerticalAlignment="Center" |
| 51 | + FontSize="14" |
| 52 | + Text="{DynamicResource flowlauncher_plugin_url_browser_path}" /> |
| 53 | + <Grid |
| 54 | + Grid.Row="0" |
| 55 | + Grid.Column="1" |
| 56 | + Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"> |
| 57 | + <Grid.ColumnDefinitions> |
| 58 | + <ColumnDefinition Width="*" /> |
| 59 | + <ColumnDefinition Width="Auto" /> |
| 60 | + </Grid.ColumnDefinitions> |
| 61 | + |
| 62 | + <TextBox |
| 63 | + Grid.Column="0" |
| 64 | + HorizontalAlignment="Stretch" |
| 65 | + VerticalAlignment="Center" |
| 66 | + IsReadOnly="True" |
| 67 | + Text="{Binding Settings.BrowserPath, Mode=OneWay}" /> |
| 68 | + <Button |
| 69 | + Grid.Column="1" |
| 70 | + Margin="{StaticResource SettingPanelItemLeftMargin}" |
| 71 | + HorizontalAlignment="Left" |
| 72 | + VerticalAlignment="Center" |
| 73 | + Click="SelectBrowserPath" |
| 74 | + Content="{DynamicResource flowlauncher_plugin_url_plugin_choose}" /> |
| 75 | + </Grid> |
| 76 | + |
| 77 | + <StackPanel |
| 78 | + Grid.Row="1" |
| 79 | + Grid.Column="1" |
| 80 | + Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}" |
| 81 | + Orientation="Horizontal"> |
| 82 | + <RadioButton Content="{DynamicResource flowlauncher_plugin_url_new_tab}" IsChecked="{Binding Settings.OpenInNewBrowserWindow, Converter={StaticResource InverseBoolConverter}, Mode=TwoWay}" /> |
| 83 | + <RadioButton Content="{DynamicResource flowlauncher_plugin_url_new_window}" IsChecked="{Binding Settings.OpenInNewBrowserWindow, Mode=TwoWay}" /> |
| 84 | + </StackPanel> |
| 85 | + |
| 86 | + <TextBlock |
| 87 | + Grid.Row="2" |
| 88 | + Grid.Column="0" |
| 89 | + Margin="{StaticResource SettingPanelItemTopBottomMargin}" |
| 90 | + VerticalAlignment="Center" |
| 91 | + FontSize="14" |
| 92 | + Text="{DynamicResource flowlauncher_plugin_url_private_mode}" /> |
| 93 | + <Grid |
| 94 | + Grid.Row="2" |
| 95 | + Grid.Column="1" |
| 96 | + Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"> |
| 97 | + <Grid.ColumnDefinitions> |
| 98 | + <ColumnDefinition Width="*" /> |
| 99 | + <ColumnDefinition Width="Auto" /> |
| 100 | + </Grid.ColumnDefinitions> |
| 101 | + |
| 102 | + <TextBox |
| 103 | + Grid.Column="0" |
| 104 | + HorizontalAlignment="Stretch" |
| 105 | + VerticalAlignment="Center" |
| 106 | + Text="{Binding Settings.PrivateModeArgument, Mode=TwoWay}" /> |
| 107 | + <CheckBox |
| 108 | + Grid.Column="1" |
| 109 | + Margin="{StaticResource SettingPanelItemLeftMargin}" |
| 110 | + HorizontalAlignment="Left" |
| 111 | + VerticalAlignment="Center" |
| 112 | + Content="" |
| 113 | + IsChecked="{Binding Settings.OpenInPrivateMode, Mode=TwoWay}" /> |
| 114 | + </Grid> |
| 115 | + </Grid> |
| 116 | + </Grid> |
| 117 | +</UserControl> |
0 commit comments