Просмотр исходного кода

优化UI。

tags/录制修改前
zhangxueyang 4 лет назад
Родитель
Сommit
0bb0a0d521

+ 2
- 1
XHWK.WKTool/CountdownWindow.xaml Просмотреть файл

@@ -21,6 +21,7 @@
21 21
                     gifLib:ImageBehavior.AnimatedSource=".\Images\countdown.gif" MediaElement.MediaEnded="Image_MediaEnded"/>-->
22 22
         <Image x:Name="imgLoding"
23 23
                     Source=".\Images\countdown3_1.png" HorizontalAlignment="Center" VerticalAlignment="Center" Width="300" />
24
-        <Label x:Name="lblShortcut" Content="开始/暂停:Ctrl+F5     停止:Ctrl+S" Height="77" Margin="0,450,0,0" Width="682" Foreground="#FF5B5151" FontSize="36" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Visibility="Collapsed"/>
24
+        <Border x:Name="borShortcut" Margin="0,450,0,0" Height="60" Width="550" Opacity="0.3"  Background="#999999"  CornerRadius="30"/>
25
+        <Label x:Name="lblShortcut" Content="开始/暂停:Ctrl+F5     停止:Ctrl+S" Height="60" Margin="0,450,0,0" Width="682" FontWeight="Bold" Foreground="#FFFFFF"   FontSize="30" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Visibility="Visible"/>
25 26
     </Grid>
26 27
 </Window>

+ 2
- 0
XHWK.WKTool/CountdownWindow.xaml.cs Просмотреть файл

@@ -27,10 +27,12 @@ namespace XHWK.WKTool
27 27
             if (ShowlblShortcut)
28 28
             {
29 29
                 lblShortcut.Visibility = Visibility.Visible;
30
+                borShortcut.Visibility = Visibility.Visible;
30 31
             }
31 32
             else
32 33
             {
33 34
                 lblShortcut.Visibility = Visibility.Hidden;
35
+                borShortcut.Visibility = Visibility.Hidden;
34 36
             }
35 37
             ImgNum = 22;
36 38
             bool IsStart = true;

+ 12
- 12
XHWK.WKTool/CreateAMicroLessonWindow.xaml Просмотреть файл

@@ -16,35 +16,35 @@
16 16
         <Grid.RowDefinitions>
17 17
             <RowDefinition Height="45"/>
18 18
             <RowDefinition Height="110"/>
19
-            <RowDefinition Height="80"/>
19
+            <RowDefinition Height="70"/>
20 20
             <RowDefinition Height="*"/>
21 21
         </Grid.RowDefinitions>
22 22
         <!--第一行 标题-->
23 23
         <Border Grid.Row="0" Background="#2D8CF0" MouseLeftButtonDown="Window_MouseLeftButtonDown" Grid.ColumnSpan="2">
24 24
             <Grid>
25 25
                 <TextBlock Text="创建微课" Foreground="#FFFFFF" FontSize="16" Padding="10,13,0,0"/>
26
-                <Button  Cursor="Hand" Grid.Row="0" x:Name="btnDown" Content="×" Foreground="#FFFFFF" FontSize="28" Padding="10,0,10,0" HorizontalAlignment="Right" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Click="BtnDown_Click"/>
26
+                <Button  Cursor="Hand" Grid.Row="0" x:Name="btnDown" Content="×" VerticalAlignment="Top" Foreground="#FFFFFF" FontSize="30" Padding="10,2,10,0" HorizontalAlignment="Right" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Click="BtnDown_Click"/>
27 27
             </Grid>
28 28
         </Border>
29 29
         <!--第二行 讲解名称-->
30
-        <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="10,40,0,1" Grid.ColumnSpan="2">
31
-            <Label Content="*" FontSize="18" Padding="0,27,0,0" Foreground="#FF0000"/>
32
-            <TextBlock Text="讲解名称" FontSize="18" Padding="2,23,10,0"/>
30
+        <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="30,20,30,1" Grid.ColumnSpan="2">
31
+            <Label Content="*" FontSize="18" Padding="0,37.5,0,0" Foreground="#FF0000"/>
32
+            <TextBlock Text="讲解名称" FontSize="18" Padding="2,33,10,0"/>
33 33
             <!--输入框-->
34
-            <Border Background="#CDD6E0" Width="321" Height="43" CornerRadius="3">
35
-                <TextBox x:Name="txbExplainName" Text="微课1" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="319" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
34
+            <Border Background="#CDD6E0" Width="291" Height="43" CornerRadius="3">
35
+                <TextBox x:Name="txbExplainName" Text="微课1" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="289" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
36 36
             </Border>
37 37
         </StackPanel>
38 38
         <!--第三行 存放路径-->
39
-        <StackPanel Grid.Row="2" Orientation="Horizontal" Margin="10,10,0,1" Grid.ColumnSpan="2">
39
+        <StackPanel Grid.Row="2" Orientation="Horizontal" Margin="30,0,30,1" Grid.ColumnSpan="2">
40 40
             <Label Content="*" FontSize="18" Padding="0,27,0,0" Foreground="#FF0000"/>
41 41
             <TextBlock Text="存放路径" FontSize="18" Padding="2,23,10,0"/>
42 42
             <!--输入框-->
43
-            <Border Background="#CDD6E0" Width="225" Height="43" CornerRadius="3">
44
-                <TextBox x:Name="txbStoragePath" Text="D:\" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="223" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
43
+            <Border Background="#CDD6E0" Width="200" Height="43" CornerRadius="3">
44
+                <TextBox x:Name="txbStoragePath" Text="D:\" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="198" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
45 45
             </Border>
46 46
             <!--浏览按钮-->
47
-            <Button  Cursor="Hand" x:Name="btnBrowse" Content="浏览" FontSize="18" Width="80" Height="43" Margin="18,0,0,0" Click="BtnBrowse_Click">
47
+            <Button  Cursor="Hand" x:Name="btnBrowse" Content="浏览" FontSize="18" Width="80" Height="43" Margin="11,0,0,0" Click="BtnBrowse_Click">
48 48
                 <Button.Template>
49 49
                     <ControlTemplate TargetType="{x:Type Button}">
50 50
                         <Border
@@ -62,7 +62,7 @@
62 62
             </Button>
63 63
         </StackPanel>
64 64
         <!--第四行 开始按钮-->
65
-        <Button  Cursor="Hand" Grid.Row="3" x:Name="btnStart" Content="开始" FontSize="18" FontWeight="Bold" Foreground="#FFFFFF" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="418" Height="48" Margin="10,0,10,0" Click="BtnStart_Click" Grid.ColumnSpan="2">
65
+        <Button  Cursor="Hand" Grid.Row="3" x:Name="btnStart" Content="开始" FontSize="18" FontWeight="Bold" Foreground="#FFFFFF" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="386" Height="48" Margin="30,0,30,0" Click="BtnStart_Click" Grid.ColumnSpan="2">
66 66
             <Button.Template>
67 67
                 <ControlTemplate TargetType="{x:Type Button}">
68 68
                     <Border

+ 14
- 13
XHWK.WKTool/KeyVerification.xaml Просмотреть файл

@@ -49,7 +49,7 @@
49 49
             </StackPanel>
50 50
         </DataTemplate>
51 51
     </Window.Resources>
52
-    <Views:ZJClippingBorder Background="White" CornerRadius="10,10,10,10">
52
+    <Views:ZJClippingBorder Background="White">
53 53
         <Grid Margin="0,0,0,0">
54 54
             <Grid.RowDefinitions>
55 55
                 <RowDefinition Height="50" />
@@ -67,10 +67,10 @@
67 67
                     Margin="15,0,0,0"
68 68
                     HorizontalAlignment="Left"
69 69
                     VerticalAlignment="Center"
70
-                    FontSize="22"
70
+                    FontSize="16"
71 71
                     Foreground="White"
72 72
                     Text="产品激活" />
73
-                <Button
73
+                <!--<Button
74 74
                     Grid.Column="0"
75 75
                     Width="46"
76 76
                     Height="46"
@@ -100,31 +100,32 @@
100 100
                         VerticalAlignment="Center"
101 101
                         Source="./Images/rollCall_1.png"
102 102
                         Stretch="Fill" />
103
-                </Button>
103
+                </Button>-->
104
+                <Button  Cursor="Hand" Grid.Row="0" x:Name="btnDown" Content="×" VerticalAlignment="Top" Foreground="#FFFFFF" FontSize="30" Padding="10,2,10,0" HorizontalAlignment="Right" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Click="close_click"/>
104 105
             </Grid>
105
-            <Grid Grid.Row="1" Margin="10,20,0,0">
106
-                <StackPanel Orientation="Horizontal" Height="30">
107
-                    <TextBlock Text="密匙:" FontSize="20"/>
108
-                    <TextBox x:Name="txbKey" Text="" Width="200" Foreground="gray" FontSize="18"/>
106
+            <Grid Grid.Row="1" Margin="30,20,30,0">
107
+                <StackPanel Orientation="Horizontal" Height="43">
108
+                    <TextBlock Text="密匙:" FontSize="20" Padding="0,5,0,0"/>
109
+                    <TextBox x:Name="txbKey" Text="" Width="164" Foreground="gray" FontSize="18" VerticalContentAlignment="Center"/>
109 110
                 </StackPanel>
110 111
             </Grid>
111 112
 
112 113
             <Button Cursor="Hand"
113 114
                 x:Name="btnEnd"
114 115
                 Grid.Row="2"
115
-                Width="163.5"
116
-                Height="37.2"
117
-                Margin="0,0,0,0"
116
+                Height="48"
117
+                Margin="30,0,30,0"
118 118
                 Click="btnEnd_Click"
119 119
                 Content="验证"
120
-                FontSize="18.75"
120
+                    FontWeight="Bold"
121
+                FontSize="18"
121 122
                 Foreground="White">
122 123
                 <Button.Template>
123 124
                     <ControlTemplate TargetType="{x:Type Button}">
124 125
                         <Border
125 126
                             BorderBrush="{TemplateBinding Control.BorderBrush}"
126 127
                             BorderThickness="0"
127
-                            CornerRadius="20">
128
+                            CornerRadius="3">
128 129
                             <Border.Background>#6098FF</Border.Background>
129 130
                             <ContentPresenter
130 131
                                 HorizontalAlignment="Center"

+ 52
- 9
XHWK.WKTool/LoginWindow.xaml Просмотреть файл

@@ -12,7 +12,50 @@
12 12
     <Window.Effect>
13 13
         <DropShadowEffect BlurRadius="10" Color="#bababa" Direction="80" ShadowDepth="0"/>
14 14
     </Window.Effect>
15
+    <Window.Resources>
16
+        <Style x:Key="CheckBoxStyle1" TargetType="{x:Type CheckBox}">
17
+            <Setter Property="OverridesDefaultStyle" Value="True"/>
18
+            <Setter Property="SnapsToDevicePixels" Value="True"/>
19
+            <Setter Property="Template">
20
+                <Setter.Value>
21
+                    <ControlTemplate TargetType="{x:Type CheckBox}">
22
+                        <BulletDecorator FlowDirection="LeftToRight" VerticalAlignment="Center">
23
+                            <BulletDecorator.Bullet>
24
+                                <Border x:Name="bd"  
25
+                                    BorderThickness="1"  
26
+                                    BorderBrush="#B2B2B2"  
27
+                                    MinHeight="13"  
28
+                                    MinWidth="13"  
29
+                                    VerticalAlignment="Center" Background="White">
30
+                                    <Path x:Name="cp" Width="12" Height="12"  
31
+                                      Stroke="#4892E7"  
32
+                                      StrokeThickness="2"/>
33
+                                </Border>
15 34
 
35
+                            </BulletDecorator.Bullet>
36
+                            <TextBlock x:Name="textBlock" Margin="2,0" Text="{Binding Content, RelativeSource={RelativeSource TemplatedParent}}" FontFamily="Microsoft YaHei UI" FontSize="13.333"></TextBlock>
37
+                        </BulletDecorator>
38
+                        <!-- 
39
+                        控件触发器 
40
+                    -->
41
+                        <ControlTemplate.Triggers>
42
+                            <Trigger Property="IsChecked" Value="True">
43
+                                <!-- 画上一个勾 -->
44
+                                <Setter TargetName="cp" Property="Data"  
45
+                                    Value="M 2,6 L 5,9 11,2"/>
46
+                                <Setter Property="Foreground" TargetName="textBlock" Value="#FFE60E0E"/>
47
+
48
+                            </Trigger>
49
+                            <Trigger Property="IsMouseOver" Value="True">
50
+                                <Setter TargetName="bd" Property="BorderBrush" Value="#1583DD">
51
+                                </Setter>
52
+                            </Trigger>
53
+                        </ControlTemplate.Triggers>
54
+                    </ControlTemplate>
55
+                </Setter.Value>
56
+            </Setter>
57
+        </Style>
58
+    </Window.Resources>
16 59
     <Grid Background="#FFFFFF">
17 60
         <!--分5行-->
18 61
         <Grid.RowDefinitions>
@@ -30,30 +73,30 @@
30 73
             </Grid>
31 74
         </Border>
32 75
         <!--第二行 登陆 账号-->
33
-        <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="20,30,0,0">
76
+        <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="30,30,30,0">
34 77
             <TextBlock Text="登陆" FontSize="18" Padding="2,15,10,0"/>
35 78
             <!--输入框-->
36
-            <Border Background="#cccbce" Width="369" Height="43" CornerRadius="3" Margin="0,0,0,1">
37
-                <TextBox x:Name="txbAccountNumber" Text="" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="367" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
79
+            <Border Background="#cccbce" Width="344" Height="43" CornerRadius="3" Margin="0,0,0,1">
80
+                <TextBox x:Name="txbAccountNumber" Text="" FontSize="16" Foreground="#333333" Padding="5,12,2,2" Width="342" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
38 81
             </Border>
39 82
         </StackPanel>
40 83
         <!--第三行 密码-->
41
-        <StackPanel Grid.Row="2" Orientation="Horizontal" Margin="20,30,0,1">
84
+        <StackPanel Grid.Row="2" Orientation="Horizontal" Margin="30,30,0,1">
42 85
             <TextBlock Text="密码" FontSize="18" Padding="2,15,10,0"/>
43 86
             <!--输入框-->
44
-            <Border Background="#cccbce" Width="369" Height="43" CornerRadius="3">
45
-                <PasswordBox x:Name="pobPassword" FontSize="16" Foreground="#333333" PasswordChar="*" Padding="5,12,2,2" Width="367" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
87
+            <Border Background="#cccbce" Width="344" Height="43" CornerRadius="3">
88
+                <PasswordBox x:Name="pobPassword" FontSize="16" Foreground="#333333" PasswordChar="*" Padding="5,12,2,2" Width="342" Height="41" BorderBrush="{x:Null}" BorderThickness="0"/>
46 89
             </Border>
47 90
         </StackPanel>
48
-        <StackPanel Grid.Row="3" Orientation="Horizontal" HorizontalAlignment="Left" Margin="20,10,0,0">
91
+        <StackPanel Grid.Row="3" Orientation="Horizontal" HorizontalAlignment="Left" Margin="32,10,0,0">
49 92
             <Viewbox Height="23">
50
-                <CheckBox   x:Name="ckSaveName" Click="CkSaveName_Click"/>
93
+                <CheckBox Cursor="Hand"  x:Name="ckSaveName" Click="CkSaveName_Click"   Style="{DynamicResource CheckBoxStyle1}"/>
51 94
             </Viewbox>
52 95
             <TextBlock Text="记住账号" FontSize="18" Height="30" Padding="5,3,0,0" Margin="0,0,0,1"/>
53 96
         </StackPanel>
54 97
 
55 98
         <!--第五行 开始按钮-->
56
-        <Button  Cursor="Hand" Grid.Row="4" x:Name="btnStart" Content="登录" FontSize="18" Foreground="#FFFFFF" FontWeight="Bold" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="418" Height="48" Margin="10,0,10,0" Click="BtnStart_Click">
99
+        <Button  Cursor="Hand" Grid.Row="4" x:Name="btnStart" Content="登录" FontSize="18" Foreground="#FFFFFF" FontWeight="Bold" Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" Width="394" Height="48" Margin="30,0,30,0" Click="BtnStart_Click">
57 100
             <Button.Template>
58 101
                 <ControlTemplate TargetType="{x:Type Button}">
59 102
                     <Border

+ 12
- 3
XHWK.WKTool/UControl/Uc_VideoItem.xaml Просмотреть файл

@@ -7,10 +7,19 @@
7 7
              mc:Ignorable="d" 
8 8
              d:DesignHeight="260" d:DesignWidth="250">
9 9
     <Grid>
10
-        <Button x:Name="BtnVideoPlay" HorizontalAlignment="Center" Width="200" Height="130" Margin="25,10,25,0" VerticalAlignment="Top" Cursor="Hand" Click="BtnVideoPlay_Click">
10
+        <Border Background="#dddddd" Width="202" Height="128" Margin="25,10,25,0" VerticalAlignment="Top">
11
+        <Button  x:Name="BtnVideoPlay" 
12
+            Style="{StaticResource {x:Static ToolBar.ButtonStyleKey}}" HorizontalAlignment="Center" Width="200" Height="130" Margin="1,1,1,1"  Cursor="Hand" Click="BtnVideoPlay_Click">
11 13
             <Image x:Name="ImgVideo" VerticalAlignment="Top"  Width="200" Height="130" Margin="0,0,0,0" Cursor="Hand" Stretch="Fill"/>
12 14
         </Button>
13
-        <Image x:Name="ImgVideoPlay" Source="/星火微课;component/Images/VideoList_Play.png" HorizontalAlignment="Center" VerticalAlignment="Top" Width="60" Margin="0,50,0,0" Cursor="Hand" MouseLeftButtonDown="Image_MouseLeftButtonDown" />
15
+        </Border>
16
+        <Border Background="#dddddd" VerticalAlignment="Top" Width="60" Height="60" Margin="0,50,0,0" CornerRadius="30" >
17
+     
18
+                <Image x:Name="ImgVideoPlay" Source="/星火微课;component/Images/VideoList_Play.png" HorizontalAlignment="Center" Width="58" Height="58" Margin="1,1,1,1" Cursor="Hand" MouseLeftButtonDown="Image_MouseLeftButtonDown" />
19
+   
20
+
21
+           
22
+        </Border>
14 23
         <TextBlock x:Name="TbName" Text="一二三四五六七八九十一..." HorizontalAlignment="Center" Margin="15,150,15,0" TextWrapping="Wrap" VerticalAlignment="Top" Foreground="#FF3492F4" FontSize="18" TextAlignment="Center" ToolTip="" Visibility="Visible" MouseLeftButtonDown="TextBlock_MouseLeftButtonDown"/>
15 24
         <TextBox x:Name="TxtModify" HorizontalAlignment="Left" Height="30" Margin="25,147,0,0" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="180" FontSize="16" Visibility="Hidden" LostFocus="TxtModify_LostFocus" KeyUp="TxtModify_KeyUp">
16 25
             <TextBox.Resources>
@@ -27,7 +36,7 @@
27 36
                     <Setter Property="BorderBrush" Value="#3492F4"/>
28 37
                 </Style>
29 38
             </Button.Resources>
30
-            <Image Source="/星火微课;component/Images/VideoList_OK.png"></Image>
39
+            <Image Source="/星火微课;component/Images/VideoList_OK.png" Margin="2,12,2,2"></Image>
31 40
         </Button>
32 41
 
33 42
         <Label x:Name="lblDateSize" Content="2020-10-10 10:10:00|1000.00MB" HorizontalAlignment="Center" Margin="0,175,0,0" VerticalAlignment="Top" Height="30" Width="240" Foreground="#FF9A9A9A" FontSize="13" HorizontalContentAlignment="Center"/>

+ 1
- 1
XHWK.WKTool/XHMicroLessonSystemWindow.xaml Просмотреть файл

@@ -191,7 +191,7 @@
191 191
                 <!--第一行-->
192 192
                 <StackPanel Grid.Row="0" Orientation="Horizontal" Margin="10,2,10,0">
193 193
                     <Image Source="./Images/microLessonSystem_0.png"/>
194
-                    <TextBlock Text="星火微课系统" FontSize="14" Padding="5,0,0,0" Foreground="#FFFFFF"/>
194
+                    <TextBlock Text="星火微课系统" FontSize="14" Padding="5,2,0,0" Foreground="#FFFFFF"/>
195 195
                 </StackPanel>
196 196
 
197 197
                 <StackPanel Grid.Row="0" Orientation="Horizontal" HorizontalAlignment="Right" Margin="10,2,20,0">

Загрузка…
Отмена
Сохранить