Переглянути джерело

reformate xaml
reversion to v1.3.1

Robert 3 роки тому
батько
коміт
d50d9b8cea
3 змінених файлів з 297 додано та 92 видалено
  1. 232 62
      AwInitilizer/MainWindow.xaml
  2. 64 29
      AwInitilizer/SigninDialog.xaml
  3. 1 1
      GitVersion.yml

+ 232 - 62
AwInitilizer/MainWindow.xaml

@@ -1,74 +1,171 @@
-<Window x:Class="AwInitilizer.MainWindow"
-        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
-        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+<Window
+    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     xmlns:input="clr-namespace:System.Windows.Input;assembly=PresentationCore"
-        xmlns:local="clr-namespace:AwInitilizer"
-        mc:Ignorable="d"
-        Title="Initlizer" Height="1080" Width="1920" Background="#FF363535"
-        input:InputMethod.IsInputMethodEnabled="False"
-        WindowStartupLocation="CenterScreen"
-        WindowState="Maximized"
-        x:Name="uxManinWindow">
-    <Window.Resources>
-    </Window.Resources>
+    xmlns:local="clr-namespace:AwInitilizer"
+    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+    x:Name="uxManinWindow"
+    Title="Initlizer"
+    Width="1920"
+    Height="1080"
+    input:InputMethod.IsInputMethodEnabled="False"
+    Background="#FF363535"
+    WindowStartupLocation="CenterScreen"
+    WindowState="Maximized"
+    mc:Ignorable="d"
+    x:Class="AwInitilizer.MainWindow">
+    <Window.Resources />
     <Viewbox>
         <StackPanel Orientation="Vertical">
             <StackPanel Orientation="Horizontal">
-                <StackPanel Orientation="Vertical" Width="400" Margin="10,0,0,0">
+                <StackPanel
+                    Width="400"
+                    Margin="10,0,0,0"
+                    Orientation="Vertical">
                     <GroupBox>
                         <GroupBox.Header>
-                            <Label Content="{DynamicResource Account}" Foreground="White" FontSize="16"/>
+                            <Label
+                                FontSize="16"
+                                Content="{DynamicResource Account}"
+                                Foreground="White" />
                         </GroupBox.Header>
                         <StackPanel Orientation="Vertical">
-                            <Button Width="100" Click="Logout_Click" IsEnabled="{Binding IsInputLock}">
-                                <Label Content="{DynamicResource logout}"/>
+                            <Button
+                                Width="100"
+                                Click="Logout_Click"
+                                IsEnabled="{Binding IsInputLock}">
+                                <Label Content="{DynamicResource logout}" />
                             </Button>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,10,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,10,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource UserID}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource UserID}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox Text="{Binding UserID}" IsEnabled="{Binding IsInputLock}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center"/>
+                                <TextBox
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding UserID}"
+                                    FontSize="16"
+                                    IsEnabled="{Binding IsInputLock}"
+                                    IsReadOnly="True"
+                                    TextAlignment="Center" />
                             </StackPanel>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,0,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,0,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource WorkOrder}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource WorkOrder}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox Text="{Binding WorkOrder}" IsEnabled="{Binding IsInputLock}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center"
-                                     TextChanged="WorkOrder_TextChanged" KeyDown="WorkOrder_KeyDown"/>
+                                <TextBox
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding WorkOrder}"
+                                    FontSize="16"
+                                    IsEnabled="{Binding IsInputLock}"
+                                    IsReadOnly="True"
+                                    KeyDown="WorkOrder_KeyDown"
+                                    TextAlignment="Center"
+                                    TextChanged="WorkOrder_TextChanged" />
                             </StackPanel>
-                            
+
                         </StackPanel>
                     </GroupBox>
                     <GroupBox>
                         <GroupBox.Header>
-                            <Label Content="{DynamicResource BarcodeSetting}" Foreground="White" FontSize="16"/>
+                            <Label
+                                FontSize="16"
+                                Content="{DynamicResource BarcodeSetting}"
+                                Foreground="White" />
                         </GroupBox.Header>
                         <StackPanel Orientation="Vertical">
-                            <StackPanel Orientation="Horizontal" Height="30">
+                            <StackPanel Height="30" Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource ModelName}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource ModelName}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox x:Name="uxModelName" Text="{Binding ModelName}" IsEnabled="{Binding IsInputLock}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center"/>
+                                <TextBox
+                                    x:Name="uxModelName"
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding ModelName}"
+                                    FontSize="16"
+                                    IsEnabled="{Binding IsInputLock}"
+                                    IsReadOnly="True"
+                                    TextAlignment="Center" />
                             </StackPanel>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,10,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,10,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource SerialNumber}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource SerialNumber}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox x:Name="uxSerialNumber" Text="{Binding SerialNumber}" IsEnabled="{Binding IsInputLock}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center"/>
+                                <TextBox
+                                    x:Name="uxSerialNumber"
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding SerialNumber}"
+                                    FontSize="16"
+                                    IsEnabled="{Binding IsInputLock}"
+                                    IsReadOnly="True"
+                                    TextAlignment="Center" />
                             </StackPanel>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,0,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,0,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource SimStatus}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource SimStatus}"
+                                        Foreground="White" />
                                 </Grid>
-                                <CheckBox x:Name="uxIsSimCheckEnabled" IsChecked="{Binding IsSimInsert}" IsEnabled="{Binding IsInputLock}" IsHitTestVisible="False" VerticalAlignment="Center" />
+                                <CheckBox
+                                    x:Name="uxIsSimCheckEnabled"
+                                    VerticalAlignment="Center"
+                                    IsChecked="{Binding IsSimInsert}"
+                                    IsEnabled="{Binding IsInputLock}"
+                                    IsHitTestVisible="False" />
                             </StackPanel>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,0,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,0,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource ICCID}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource ICCID}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox x:Name="uxICCID" Text="{Binding ICCID}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center">
+                                <TextBox
+                                    x:Name="uxICCID"
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding ICCID}"
+                                    FontSize="16"
+                                    IsReadOnly="True"
+                                    TextAlignment="Center">
                                     <TextBox.IsEnabled>
                                         <MultiBinding Converter="{StaticResource booleanAndConverter}">
                                             <Binding Path="IsSimInsert" />
@@ -77,11 +174,25 @@
                                     </TextBox.IsEnabled>
                                 </TextBox>
                             </StackPanel>
-                            <StackPanel Orientation="Horizontal" Height="30" Margin="0,0,0,10">
+                            <StackPanel
+                                Height="30"
+                                Margin="0,0,0,10"
+                                Orientation="Horizontal">
                                 <Grid Width="178">
-                                    <Label Content="{DynamicResource IMSI}" Foreground="White" FontSize="16" HorizontalAlignment="Center"/>
+                                    <Label
+                                        HorizontalAlignment="Center"
+                                        FontSize="16"
+                                        Content="{DynamicResource IMSI}"
+                                        Foreground="White" />
                                 </Grid>
-                                <TextBox x:Name="uxIMSI" Text="{Binding IMSI}" IsReadOnly="True" Width="200" FontSize="16" TextAlignment="Center" VerticalContentAlignment="Center">
+                                <TextBox
+                                    x:Name="uxIMSI"
+                                    Width="200"
+                                    VerticalContentAlignment="Center"
+                                    Text="{Binding IMSI}"
+                                    FontSize="16"
+                                    IsReadOnly="True"
+                                    TextAlignment="Center">
                                     <TextBox.IsEnabled>
                                         <MultiBinding Converter="{StaticResource booleanAndConverter}">
                                             <Binding Path="IsSimInsert" />
@@ -94,17 +205,39 @@
                     </GroupBox>
                 </StackPanel>
 
-                <StackPanel Orientation="Vertical" Width="400" Margin="10,0,0,0">
+                <StackPanel
+                    Width="400"
+                    Margin="10,0,0,0"
+                    Orientation="Vertical">
                     <GroupBox>
                         <GroupBox.Header>
-                            <Label Content="{DynamicResource FirmwareVersion}" Foreground="White" FontSize="16"/>
+                            <Label
+                                FontSize="16"
+                                Content="{DynamicResource FirmwareVersion}"
+                                Foreground="White" />
                         </GroupBox.Header>
 
-                        <DataGrid AutoGenerateColumns="False" Margin="10" Height="335" CanUserSortColumns="False" IsEnabled="{Binding IsInputLock}" ItemsSource="{Binding FirmwareUpdateModels}">
+                        <DataGrid
+                            Height="335"
+                            Margin="10"
+                            AutoGenerateColumns="False"
+                            CanUserSortColumns="False"
+                            IsEnabled="{Binding IsInputLock}"
+                            ItemsSource="{Binding FirmwareUpdateModels}">
                             <DataGrid.Columns>
-                                <DataGridTextColumn Header="{DynamicResource FirmwareVersionHeaderName}" Width="150" MinWidth="50" Binding="{Binding Path=Module}" IsReadOnly="True"/>
-                                <DataGridTextColumn Header="{DynamicResource FirmwareVersionHeaderVersion}" Width="150" MinWidth="70" Binding="{Binding Path=Version}" IsReadOnly="True"/>
-                                <!--" DataGridTextColumn Header="File name" Binding="{Binding Path=FirmwareFileName}" IsReadOnly="False"/-->
+                                <DataGridTextColumn
+                                    Width="150"
+                                    MinWidth="50"
+                                    Binding="{Binding Path=Module}"
+                                    Header="{DynamicResource FirmwareVersionHeaderName}"
+                                    IsReadOnly="True" />
+                                <DataGridTextColumn
+                                    Width="150"
+                                    MinWidth="70"
+                                    Binding="{Binding Path=Version}"
+                                    Header="{DynamicResource FirmwareVersionHeaderVersion}"
+                                    IsReadOnly="True" />
+                                <!--  " DataGridTextColumn Header="File name" Binding="{Binding Path=FirmwareFileName}" IsReadOnly="False"/  -->
                             </DataGrid.Columns>
                         </DataGrid>
                     </GroupBox>
@@ -112,19 +245,27 @@
 
                 <Grid Margin="10,0,0,0">
                     <Grid.RowDefinitions>
-                        <RowDefinition Height="*"/>
-                        <RowDefinition Height="30"/>
-                        <RowDefinition Height="*"/>
+                        <RowDefinition Height="*" />
+                        <RowDefinition Height="30" />
+                        <RowDefinition Height="*" />
                     </Grid.RowDefinitions>
 
-                    <Button Grid.Row="0" Margin="30" x:Name="uxStartBtn" Click="StartInit_Click">
+                    <Button
+                        x:Name="uxStartBtn"
+                        Grid.Row="0"
+                        Margin="30"
+                        Click="StartInit_Click">
                         <Button.Template>
                             <ControlTemplate TargetType="Button">
-                                <Border CornerRadius="10" BorderThickness="2" BorderBrush="Gray" Background="White">
+                                <Border
+                                    Background="White"
+                                    BorderBrush="Gray"
+                                    BorderThickness="2"
+                                    CornerRadius="10">
                                     <Border.Effect>
-                                        <DropShadowEffect ShadowDepth="10"/>
+                                        <DropShadowEffect ShadowDepth="10" />
                                     </Border.Effect>
-                                    <ContentPresenter VerticalAlignment="Center" HorizontalAlignment="Center"/>
+                                    <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" />
                                 </Border>
                             </ControlTemplate>
                         </Button.Template>
@@ -135,23 +276,52 @@
                             </MultiBinding>
                         </Button.IsEnabled>
 
-                        <Label FontSize="36" Content="{DynamicResource StartProcedure}"/>
+                        <Label FontSize="36" Content="{DynamicResource StartProcedure}" />
                     </Button>
 
                     <StackPanel Grid.Row="1" Orientation="Vertical">
-                        <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
-                            <ProgressBar Minimum="0" Maximum="100" x:Name="uxProgress" VerticalAlignment="Center" Height="20" Width="250"/>
-                            <Label x:Name="uxProgressRate" Content="0%" Foreground="White" FontSize="16"/>
+                        <StackPanel
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            Orientation="Horizontal">
+                            <ProgressBar
+                                x:Name="uxProgress"
+                                Width="250"
+                                Height="20"
+                                VerticalAlignment="Center"
+                                Maximum="100"
+                                Minimum="0" />
+                            <Label
+                                x:Name="uxProgressRate"
+                                FontSize="16"
+                                Content="0%"
+                                Foreground="White" />
                         </StackPanel>
                     </StackPanel>
 
 
-                    <Grid Grid.Row="2" Background="White" Margin="30" x:Name="uxStatusContainer">
-                        <Label FontSize="36" x:Name="uxStatus" Foreground="Black" Content="Idel" VerticalAlignment="Center" HorizontalAlignment="Center"/>
+                    <Grid
+                        x:Name="uxStatusContainer"
+                        Grid.Row="2"
+                        Margin="30"
+                        Background="White">
+                        <Label
+                            x:Name="uxStatus"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            FontSize="36"
+                            Content="Idel"
+                            Foreground="Black" />
                     </Grid>
                 </Grid>
             </StackPanel>
-            <Label x:Name="uxStatusBar" FontSize="36" Content="" Margin="0,10,0,0" Foreground="White" HorizontalAlignment="Center"/>
+            <Label
+                x:Name="uxStatusBar"
+                Margin="0,10,0,0"
+                HorizontalAlignment="Center"
+                FontSize="36"
+                Content=""
+                Foreground="White" />
         </StackPanel>
     </Viewbox>
 </Window>

+ 64 - 29
AwInitilizer/SigninDialog.xaml

@@ -1,44 +1,79 @@
-<Window x:Class="AwInitilizer.SigninDialog"
-        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
-        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
-        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
-        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
-        xmlns:local="clr-namespace:AwInitilizer"
-        mc:Ignorable="d"
-        Title="Signin" Height="600" Width="800"
-        ResizeMode="NoResize"
-        WindowStartupLocation="CenterOwner"
-        Topmost="True"
-        FontSize="36">
+<Window
+    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+    xmlns:local="clr-namespace:AwInitilizer"
+    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+    Title="Signin"
+    Width="800"
+    Height="600"
+    FontSize="36"
+    ResizeMode="NoResize"
+    Topmost="True"
+    WindowStartupLocation="CenterOwner"
+    mc:Ignorable="d"
+    x:Class="AwInitilizer.SigninDialog">
     <Border BorderBrush="Gray" BorderThickness="2">
         <Grid>
             <Grid.RowDefinitions>
-                <RowDefinition Height="60"/>
-                <RowDefinition Height="*"/>
+                <RowDefinition Height="60" />
+                <RowDefinition Height="*" />
             </Grid.RowDefinitions>
 
             <Grid Grid.Row="0" Background="Gray">
-                <Label x:Name="uxTitle" Content="{StaticResource SigninDialogTitle}" Foreground="White"/>
+                <Label
+                    x:Name="uxTitle"
+                    Content="{StaticResource SigninDialogTitle}"
+                    Foreground="White" />
             </Grid>
 
             <Grid Grid.Row="1">
-                <StackPanel Orientation="Vertical" VerticalAlignment="Center" >
-                    <StackPanel Orientation="Vertical" VerticalAlignment="Center" >
-                        <Label Foreground="Black" Content="{StaticResource SigninDialogEnterIDHint}" VerticalAlignment="Center" HorizontalAlignment="Center"/>
-                        <Rectangle Height="10"/>
-                        <TextBox x:Name="uxIdBox" Margin="10" Height="60" TextAlignment="Center"/>
+                <StackPanel VerticalAlignment="Center" Orientation="Vertical">
+                    <StackPanel VerticalAlignment="Center" Orientation="Vertical">
+                        <Label
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            Content="{StaticResource SigninDialogEnterIDHint}"
+                            Foreground="Black" />
+                        <Rectangle Height="10" />
+                        <TextBox
+                            x:Name="uxIdBox"
+                            Height="60"
+                            Margin="10"
+                            TextAlignment="Center" />
                     </StackPanel>
-                    <StackPanel Orientation="Vertical" VerticalAlignment="Center" >
-                        <Label Foreground="Black" Content="{StaticResource SigninDialogEnterWOHint}" VerticalAlignment="Center" HorizontalAlignment="Center"/>
-                        <Rectangle Height="10"/>
-                        <TextBox x:Name="uxWorkOrderBox" Margin="10" Height="60" TextAlignment="Center"/>
+                    <StackPanel VerticalAlignment="Center" Orientation="Vertical">
+                        <Label
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            Content="{StaticResource SigninDialogEnterWOHint}"
+                            Foreground="Black" />
+                        <Rectangle Height="10" />
+                        <TextBox
+                            x:Name="uxWorkOrderBox"
+                            Height="60"
+                            Margin="10"
+                            TextAlignment="Center" />
                     </StackPanel>
 
-                    <Label x:Name="uxErrmsg" Content="error" Foreground="Red" Visibility="Hidden" HorizontalAlignment="Center"/>
-                    <Rectangle Height="10"/>
-                    <Grid x:Name="uxCancelContainer" Grid.Row="2" Height="60">
-                        <Button  HorizontalAlignment="Center" VerticalAlignment="Center" Height="60" Width="150" Click="OK_Pressed">
-                            <Label x:Name="uxBtnText" Content="{StaticResource Confirm}"/>
+                    <Label
+                        x:Name="uxErrmsg"
+                        HorizontalAlignment="Center"
+                        Content="error"
+                        Foreground="Red"
+                        Visibility="Hidden" />
+                    <Rectangle Height="10" />
+                    <Grid
+                        x:Name="uxCancelContainer"
+                        Grid.Row="2"
+                        Height="60">
+                        <Button
+                            Width="150"
+                            Height="60"
+                            HorizontalAlignment="Center"
+                            VerticalAlignment="Center"
+                            Click="OK_Pressed">
+                            <Label x:Name="uxBtnText" Content="{StaticResource Confirm}" />
                         </Button>
                     </Grid>
                 </StackPanel>

+ 1 - 1
GitVersion.yml

@@ -1,6 +1,6 @@
 assembly-versioning-scheme: MajorMinorPatch
 assembly-informational-format: '{ShortSha}'
-next-version: 1.3.0
+next-version: 1.3.1
 branches: {}
 ignore:
   sha: []