mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Move to resource
This commit is contained in:
parent
317258af2f
commit
cd320f3de6
3 changed files with 17 additions and 12 deletions
|
|
@ -29,6 +29,8 @@ namespace Flow.Launcher.Core.Plugin
|
|||
private static readonly Thickness SettingPanelItemLeftMargin = (Thickness)Application.Current.FindResource("SettingPanelItemLeftMargin");
|
||||
private static readonly Thickness SettingPanelItemTopBottomMargin = (Thickness)Application.Current.FindResource("SettingPanelItemTopBottomMargin");
|
||||
private static readonly Thickness SettingPanelItemLeftTopBottomMargin = (Thickness)Application.Current.FindResource("SettingPanelItemLeftTopBottomMargin");
|
||||
private static readonly double SettingPanelTextBlockMinWidth = (double)Application.Current.FindResource("SettingPanelTextBlockMinWidth");
|
||||
private static readonly double SettingPanelPathTextBlockMinWidth = (double)Application.Current.FindResource("SettingPanelPathTextBlockMinWidth");
|
||||
|
||||
public async Task InitializeAsync()
|
||||
{
|
||||
|
|
@ -236,7 +238,7 @@ namespace Flow.Launcher.Core.Plugin
|
|||
{
|
||||
var textBox = new TextBox()
|
||||
{
|
||||
MinWidth = 180,
|
||||
MinWidth = SettingPanelTextBlockMinWidth,
|
||||
HorizontalAlignment = HorizontalAlignment.Left,
|
||||
VerticalAlignment = VerticalAlignment.Center,
|
||||
Margin = SettingPanelItemLeftTopBottomMargin,
|
||||
|
|
@ -258,7 +260,7 @@ namespace Flow.Launcher.Core.Plugin
|
|||
{
|
||||
var textBox = new TextBox()
|
||||
{
|
||||
MinWidth = 240,
|
||||
MinWidth = SettingPanelPathTextBlockMinWidth,
|
||||
HorizontalAlignment = HorizontalAlignment.Left,
|
||||
VerticalAlignment = VerticalAlignment.Center,
|
||||
Margin = SettingPanelItemLeftMargin,
|
||||
|
|
@ -324,7 +326,7 @@ namespace Flow.Launcher.Core.Plugin
|
|||
var textBox = new TextBox()
|
||||
{
|
||||
MaxHeight = 150,
|
||||
MinWidth = 180,
|
||||
MinWidth = SettingPanelTextBlockMinWidth,
|
||||
HorizontalAlignment = HorizontalAlignment.Left,
|
||||
VerticalAlignment = VerticalAlignment.Center,
|
||||
Margin = SettingPanelItemLeftTopBottomMargin,
|
||||
|
|
@ -347,7 +349,7 @@ namespace Flow.Launcher.Core.Plugin
|
|||
{
|
||||
var passwordBox = new PasswordBox()
|
||||
{
|
||||
MinWidth = 180,
|
||||
MinWidth = SettingPanelTextBlockMinWidth,
|
||||
HorizontalAlignment = HorizontalAlignment.Left,
|
||||
VerticalAlignment = VerticalAlignment.Center,
|
||||
Margin = SettingPanelItemLeftTopBottomMargin,
|
||||
|
|
|
|||
|
|
@ -5602,4 +5602,7 @@
|
|||
<Setter Property="VerticalAlignment" Value="Top" />
|
||||
<Setter Property="Background" Value="{DynamicResource Color03B}" />
|
||||
</Style>
|
||||
|
||||
<system:Double x:Key="SettingPanelTextBlockMinWidth">180</system:Double>
|
||||
<system:Double x:Key="SettingPanelPathTextBlockMinWidth">240</system:Double>
|
||||
</ResourceDictionary>
|
||||
|
|
|
|||
|
|
@ -174,7 +174,7 @@
|
|||
Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"
|
||||
Orientation="Horizontal">
|
||||
<TextBox
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Center"
|
||||
Text="{Binding FileEditorPath}"
|
||||
|
|
@ -201,7 +201,7 @@
|
|||
Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"
|
||||
Orientation="Horizontal">
|
||||
<TextBox
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Center"
|
||||
Text="{Binding FolderEditorPath}"
|
||||
|
|
@ -228,7 +228,7 @@
|
|||
Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"
|
||||
Orientation="Horizontal">
|
||||
<TextBox
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Center"
|
||||
Text="{Binding ShellPath}"
|
||||
|
|
@ -299,7 +299,7 @@
|
|||
<TextBox
|
||||
Grid.Row="9"
|
||||
Grid.Column="1"
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"
|
||||
HorizontalAlignment="Left"
|
||||
Text="{Binding ExcludedFileTypes}"
|
||||
|
|
@ -314,7 +314,7 @@
|
|||
<TextBox
|
||||
Grid.Row="10"
|
||||
Grid.Column="1"
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
Margin="{StaticResource SettingPanelItemLeftTopBottomMargin}"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Center"
|
||||
|
|
@ -361,7 +361,7 @@
|
|||
Grid.Row="15"
|
||||
Grid.Column="0"
|
||||
Grid.ColumnSpan="2"
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
MaxHeight="150"
|
||||
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
||||
HorizontalAlignment="Left"
|
||||
|
|
@ -381,7 +381,7 @@
|
|||
Grid.Row="17"
|
||||
Grid.Column="0"
|
||||
Grid.ColumnSpan="2"
|
||||
MinWidth="180"
|
||||
MinWidth="{StaticResource SettingPanelTextBlockMinWidth}"
|
||||
MaxHeight="150"
|
||||
Margin="{StaticResource SettingPanelItemTopBottomMargin}"
|
||||
HorizontalAlignment="Left"
|
||||
|
|
@ -529,7 +529,7 @@
|
|||
<TextBox
|
||||
Grid.Row="26"
|
||||
Grid.Column="1"
|
||||
MinWidth="240"
|
||||
MinWidth="{StaticResource SettingPanelPathTextBlockMinWidth}"
|
||||
Margin="{StaticResource SettingPanelItemRightTopBottomMargin}"
|
||||
HorizontalAlignment="Left"
|
||||
Text="{Binding EverythingInstalledPath}" />
|
||||
|
|
|
|||
Loading…
Reference in a new issue