39 lines
2.0 KiB
Plaintext
39 lines
2.0 KiB
Plaintext
|
<UserControl x:Class="DM_Weight.Views.SettingWindow"
|
||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||
|
xmlns:local="clr-namespace:DM_Weight.Views"
|
||
|
mc:Ignorable="d"
|
||
|
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||
|
d:DesignHeight="450" d:DesignWidth="800">
|
||
|
<UserControl.Resources>
|
||
|
<Style TargetType="TextBlock" BasedOn="{StaticResource MaterialDesignCaptionTextBlock}">
|
||
|
<Setter Property="Margin" Value="10 0" />
|
||
|
<Setter Property="HorizontalAlignment" Value="Center" />
|
||
|
<Setter Property="VerticalAlignment" Value="Center" />
|
||
|
</Style>
|
||
|
</UserControl.Resources>
|
||
|
<UniformGrid Rows="7" Columns="2" Width="400">
|
||
|
<TextBlock TextAlignment="Center" Text="登录模式:" />
|
||
|
<ToggleButton
|
||
|
HorizontalAlignment="Left"
|
||
|
x:Name="MaterialDesignFilledTextBoxEnabledComboBox"
|
||
|
Style="{StaticResource MaterialDesignActionToggleButton}"
|
||
|
IsChecked="{Binding LoginMode}"
|
||
|
ToolTip="登录模式"
|
||
|
Content="单人"
|
||
|
materialDesign:ToggleButtonAssist.OnContent="双人" />
|
||
|
<TextBlock TextAlignment="Center" Text="优先登录:" />
|
||
|
<ListBox VerticalAlignment="Center"
|
||
|
ItemsSource="{Binding keyValuePairs}"
|
||
|
DisplayMemberPath="Name"
|
||
|
SelectedValuePath="Code"
|
||
|
SelectedValue="{Binding FirstLogin}"
|
||
|
Style="{StaticResource MaterialDesignChoiceChipPrimaryListBox}"
|
||
|
IsEnabled="{Binding Path=IsChecked, ElementName=MaterialDesignFilledTextBoxEnabledComboBox}">
|
||
|
</ListBox>
|
||
|
<Button Margin="12" Grid.ColumnSpan="2" Content="保存" Command="{Binding ResetConfigCommand}" />
|
||
|
</UniformGrid>
|
||
|
</UserControl>
|