<UserControl x:Class="FLY.Thick.Base.UI.CustomSection.UcSectionReboot"
             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:FLY.Thick.Base.UI.CustomSection"
             mc:Ignorable="d" >
    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/FLY.ControlLibrary;component/Converter/Converters.xaml"/>
            </ResourceDictionary.MergedDictionaries>
            <local:UcSectionRebootVm x:Key="viewModel"/>
        </ResourceDictionary>
    </UserControl.Resources>
    <StackPanel Orientation="Horizontal" >
        <Border Style="{StaticResource Styles.ParamSection.Border}">
            <TextBlock Text="{StaticResource str.PgCustomSections.Reboot}" />
        </Border>
        <StackPanel d:DataContext="{StaticResource viewModel}">
            <StackPanel Orientation="Horizontal">
                <StackPanel Margin="{StaticResource ControlMargin}">
                    <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="{StaticResource str.PgCustomSections.AutoRebootAt12}" />
                    <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding IsAutoReboot}" />
                </StackPanel>
                <StackPanel Margin="{StaticResource ControlMargin}">
                    <TextBlock Style="{StaticResource Styles.Text.FieldHeader}" Text="{StaticResource str.PgCustomSections.BootTime}" />
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Style="{StaticResource Styles.Text.FieldContent}" Text="{Binding BootTimeMin}" />
                        <TextBlock Style="{StaticResource Styles.Text.FieldContent.Unit}" Text="{StaticResource str.PgCustomSections.Min}"/>
                    </StackPanel>
                </StackPanel>
                <StackPanel Margin="{StaticResource ControlMargin}">
                    <TextBlock Style="{StaticResource Styles.Text.FieldHeader.Editable.Row2}" Text="测试:立即重启" />
                    <ToggleButton Style="{StaticResource Styles.ToggleButton.YESNO}" HorizontalAlignment="Left" IsChecked="{Binding IsReBootAtOnce}" />
                </StackPanel>
            </StackPanel>
        </StackPanel>
    </StackPanel>
</UserControl>
