工作面板UI更新

This commit is contained in:
ZouJin 2024-03-28 15:28:40 +08:00
parent 51e577e673
commit d8f81687c5

View File

@ -1,44 +1,37 @@
<pu:WindowX x:Class="VPet_Simulator.Windows.winWorkMenu" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
<pu:WindowX x:Class="VPet_Simulator.Windows.winWorkMenu"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:pu="https://opensource.panuon.com/wpf-ui"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ll="clr-namespace:LinePutScript.Localization.WPF;assembly=LinePutScript.Localization.WPF"
xmlns:local="clr-namespace:VPet_Simulator.Windows" mc:Ignorable="d" Title="{ll:Str 工作面板}" Height="350" Style="{DynamicResource BaseWindowXStyle}"
Background="{DynamicResource PrimaryLighter}" Width="600" ResizeMode="CanMinimize" Closed="Window_Closed">
xmlns:local="clr-namespace:VPet_Simulator.Windows" mc:Ignorable="d" Title="{ll:Str 工作面板}" Height="350"
Style="{DynamicResource BaseWindowXStyle}" Background="{DynamicResource PrimaryLighter}" Width="600"
ResizeMode="CanMinimize" Closed="Window_Closed">
<Grid>
<Grid >
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="140" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Border Background="{DynamicResource DARKPrimaryText}" />
<StackPanel Margin="12, 10">
<TextBlock Text="{ll:Str 工作面板}"
FontSize="18"
Margin="5"
Foreground="{DynamicResource DARKPrimary}" />
<TextBlock Text="{ll:Str 工作面板}" FontSize="18" Margin="5" Foreground="{DynamicResource DARKPrimary}" />
<ListBox x:Name="LsbCategory"
Grid.Row="1"
Margin="-12,10,-12,0"
Background="Transparent"
BorderThickness="0"
SelectedIndex="0"
pu:ListBoxHelper.ItemsPadding="15,8"
pu:ListBoxHelper.ItemsSelectedBackground="{DynamicResource DARKPrimary}"
pu:ListBoxHelper.ItemsSelectedForeground="{DynamicResource DARKPrimaryText}"
SelectionChanged="LsbCategory_SelectionChanged">
<ListBox x:Name="LsbCategory" Grid.Row="1" Margin="-12,10,-12,0" Background="Transparent"
BorderThickness="0" SelectedIndex="0" pu:ListBoxHelper.ItemsPadding="15,8"
pu:ListBoxHelper.ItemsSelectedBackground="{DynamicResource DARKPrimary}"
pu:ListBoxHelper.ItemsSelectedForeground="{DynamicResource DARKPrimaryText}"
SelectionChanged="LsbCategory_SelectionChanged">
<ListBoxItem x:Name="LsbiWork" Content="{ll:Str '工作'}" />
<ListBoxItem x:Name="LsbiStudy" Content="{ll:Str '学习'}" />
<ListBoxItem x:Name="LsbiPlay" Content="{ll:Str '玩耍'}" />
<ListBoxItem x:Name="LsbiStar" Content="{ll:Str '收藏'}" />
</ListBox>
</StackPanel>
<Grid Grid.Column="1"
Margin="15">
<Grid Grid.Column="1" Margin="15">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200"/>
<ColumnDefinition Width="15"/>
<ColumnDefinition Width="200" />
<ColumnDefinition Width="15" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<Grid>
@ -48,28 +41,28 @@
<RowDefinition />
</Grid.RowDefinitions>
<TextBlock Text="工作内容"
FontSize="{Binding FontSize, Converter={x:Static pu:Converters.DoubleMinusConverter}, ConverterParameter=2, Source={x:Static pu:GlobalSettings.Setting}}" />
<Grid Grid.Row="1"
Margin="0,3,0,0">
FontSize="{Binding FontSize, Converter={x:Static pu:Converters.DoubleMinusConverter}, ConverterParameter=2, Source={x:Static pu:GlobalSettings.Setting}}" />
<Grid Grid.Row="1" Margin="0,3,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<ComboBox x:Name="detailTypes"
Style="{DynamicResource StandardComboBoxStyle}" SelectionChanged="detailTypes_SelectionChanged" />
<ComboBox x:Name="detailTypes" Style="{DynamicResource StandardComboBoxStyle}"
SelectionChanged="detailTypes_SelectionChanged" />
</Grid>
<Image x:Name="WorkViewImage"
RenderOptions.BitmapScalingMode="HighQuality"
Grid.Row="2"
Margin="-20,0"
Stretch="Uniform"
Source="/Res/img/r_singlemoney_1.png" />
<Image x:Name="WorkViewImage" RenderOptions.BitmapScalingMode="HighQuality" Grid.Row="2"
Margin="-20,0" Stretch="Uniform" Source="/Res/img/r_singlemoney_1.png" />
<Border Grid.Row="2" VerticalAlignment="Bottom"
Background="{DynamicResource SecondaryTrans}" HorizontalAlignment="Left" Padding="5,0,5,0"
CornerRadius="10">
<TextBlock Foreground="{DynamicResource DARKPrimaryDarker}" FontSize="20">
Lv <Run Text="{Binding Text,ElementName=tbLvLimit}" FontSize="36" FontWeight="Bold" />
</TextBlock>
</Border>
</Grid>
<Border Grid.Column="2"
Background="White"
CornerRadius="4" />
<Grid Grid.Column="2"
Margin="15">
<Border Grid.Column="2" Background="White" CornerRadius="4" />
<Grid Grid.Column="2" Margin="15">
<Grid.RowDefinitions>
<RowDefinition />
<RowDefinition Height="Auto" />
@ -97,38 +90,42 @@
<ColumnDefinition Width="Auto" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<TextBlock x:Name="tbGain" VerticalAlignment="Bottom" Foreground="{DynamicResource PrimaryDarker}"
FontSize="{Binding FontSize, Converter={x:Static pu:Converters.DoublePlusConverter}, ConverterParameter=6, Source={x:Static pu:GlobalSettings.Setting}}">$金钱</TextBlock>
<TextBlock x:Name="tbSpeed" Grid.Column="2" VerticalAlignment="Bottom" Foreground="{DynamicResource PrimaryDarker}" Text="+ 4/t"/>
<TextBlock Grid.Row="2">饱腹度</TextBlock>
<TextBlock x:Name="tbFood" Grid.Row="2" Grid.Column="2" Foreground="{DynamicResource DangerBrush}" Text="- 1/t"/>
<TextBlock Grid.Row="3">口渴度</TextBlock>
<TextBlock x:Name="tbDrink" Grid.Row="3" Grid.Column="2" Foreground="{DynamicResource DangerBrush}" Text="- 4/t"/>
<TextBlock Grid.Row="4">心情</TextBlock>
<TextBlock x:Name="tbSpirit" Grid.Row="4" Grid.Column="2" Foreground="{DynamicResource DangerBrush}" Text="- 4/t"/>
<TextBlock Grid.Row="5">等级限制</TextBlock>
<TextBlock x:Name="tbLvLimit"
Grid.Row="5"
Grid.Column="2"
Foreground="{DynamicResource PrimaryDarker}" Text="- 4/t"/>
<TextBlock Grid.Row="6">花费时间</TextBlock>
<TextBlock x:Name="tbTime" Grid.Row="6" Grid.Column="2" Foreground="{DynamicResource PrimaryDarker}" Text="10 t"/>
<TextBlock Grid.Row="7">奖励倍率</TextBlock>
<TextBlock x:Name="tbBonus" Grid.Row="7" Grid.Column="2" Foreground="{DynamicResource PrimaryDarker}" Text="x2"/>
<TextBlock Grid.Row="8">倍率调整</TextBlock>
<TextBlock x:Name="tbRatio" Grid.Row="8" Grid.Column="2" Foreground="{DynamicResource PrimaryDarker}" Text="x2"/>
<Slider x:Name="wDouble" pu:SliderHelper.ThumbWidth="10" pu:SliderHelper.ThumbCornerRadius="2" pu:SliderHelper.ThumbHeight="16" pu:SliderHelper.ThumbBorderThickness="2"
Grid.Row="9"
Grid.Column="0" Grid.ColumnSpan="4" SmallChange="1" Value="1" Minimum="1" IsEnabled="False" TickFrequency="1" IsSnapToTickEnabled="True"
ValueChanged="wDouble_ValueChanged" LargeChange="1" Style="{DynamicResource StandardSliderStyle}" TickPlacement="Both" />
<TextBlock x:Name="tbGain" VerticalAlignment="Bottom"
Foreground="{DynamicResource PrimaryDarker}"
FontSize="{Binding FontSize, Converter={x:Static pu:Converters.DoublePlusConverter}, ConverterParameter=6, Source={x:Static pu:GlobalSettings.Setting}}">$金钱</TextBlock>
<TextBlock x:Name="tbSpeed" Grid.Column="2" VerticalAlignment="Bottom"
Foreground="{DynamicResource PrimaryDarker}" Text="+ 4/t" ToolTip="{ll:Str 获得效率}" />
<TextBlock Grid.Row="2" Text="{ll:Str 饱腹消耗}" />
<TextBlock x:Name="tbFood" Grid.Row="2" Grid.Column="2"
Foreground="{DynamicResource DangerBrush}" Text="- 1/t" />
<TextBlock Grid.Row="3" Text="{ll:Str 口渴消耗}" />
<TextBlock x:Name="tbDrink" Grid.Row="3" Grid.Column="2"
Foreground="{DynamicResource DangerBrush}" Text="- 4/t" />
<TextBlock Grid.Row="4" Text="{ll:Str 心情消耗}" />
<TextBlock x:Name="tbSpirit" Grid.Row="4" Grid.Column="2"
Foreground="{DynamicResource DangerBrush}" Text="- 4/t" />
<TextBlock Grid.Row="5" Text="{ll:Str 等级限制}" />
<TextBlock x:Name="tbLvLimit" Grid.Row="5" Grid.Column="2"
Foreground="{DynamicResource PrimaryDarker}" Text="- 4/t" />
<TextBlock Grid.Row="6" Text="{ll:Str 花费时间}" />
<TextBlock x:Name="tbTime" Grid.Row="6" Grid.Column="2"
Foreground="{DynamicResource PrimaryDarker}" Text="10 t" />
<TextBlock Grid.Row="7" Text="{ll:Str 奖励倍率}" />
<TextBlock x:Name="tbBonus" Grid.Row="7" Grid.Column="2"
Foreground="{DynamicResource PrimaryDarker}" Text="x2" />
<TextBlock Grid.Row="8" Text="{ll:Str 倍率调整}" />
<TextBlock x:Name="tbRatio" Grid.Row="8" Grid.Column="2"
Foreground="{DynamicResource PrimaryDarker}" Text="x2" />
<Slider x:Name="wDouble" pu:SliderHelper.ThumbWidth="10" pu:SliderHelper.ThumbCornerRadius="2"
pu:SliderHelper.ThumbHeight="16" pu:SliderHelper.ThumbBorderThickness="2" Grid.Row="9"
Grid.Column="0" Grid.ColumnSpan="4" SmallChange="1" Value="1" Minimum="1"
IsEnabled="False" TickFrequency="1" IsSnapToTickEnabled="True"
ValueChanged="wDouble_ValueChanged" LargeChange="1"
Style="{DynamicResource StandardSliderStyle}" TickPlacement="Both" />
</Grid>
<Button x:Name="btnStart"
Grid.Row="1"
Height="30"
Content="{ll:Str 开始工作}"
Style="{DynamicResource ThemedButtonStyle}"
Background="{DynamicResource PrimaryDarker}"
<Button x:Name="btnStart" Grid.Row="1" Height="30" Content="{ll:Str 开始工作}"
Style="{DynamicResource ThemedButtonStyle}" Background="{DynamicResource PrimaryDarker}"
Click="btnStart_Click" />
</Grid>
</Grid>