MainWindow.xaml
4.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
<hc:Window
x:Class="HHECS.LicenseTools.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:hc="https://handyorg.github.io/handycontrol"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
Title="授权码生成器"
Width="800"
Height="450"
FontSize="16"
ResizeMode="CanMinimize"
ShowTitle="True"
WindowStartupLocation="CenterScreen"
mc:Ignorable="d">
<Window.Resources>
<Style TargetType="StackPanel">
<Setter Property="Orientation" Value="Horizontal" />
</Style>
<Style BasedOn="{StaticResource ButtonBaseStyle}" TargetType="Button">
<Setter Property="Background" Value="#FF6CB36C" />
<Setter Property="BorderBrush" Value="#FF00A0A0" />
<Setter Property="BorderThickness" Value="2" />
<Setter Property="Foreground" Value="Black" />
<Setter Property="Width" Value="150" />
</Style>
</Window.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="200" />
</Grid.ColumnDefinitions>
<StackPanel>
<TextBlock
Width="75"
Margin="50,25,0,10"
Text="机器码:" />
<TextBox
Name="txt_MachineCode"
Width="450"
Margin="10,20,10,10" />
</StackPanel>
<Button
x:Name="btn_ClearData"
Grid.Column="1"
Width="80"
Margin="30,20,70,10"
Click="btn_ClearData_Click"
Content="清空" />
</Grid>
<StackPanel Grid.Row="1">
<TextBlock
Width="75"
Margin="50,15,0,10"
Text="客户:" />
<TextBox
x:Name="txt_Custom"
Width="240"
Margin="10,10,10,10" />
</StackPanel>
<StackPanel Grid.Row="2">
<TextBlock
Width="75"
Margin="50,15,0,10"
Text="权限角色:" />
<hc:ComboBox
x:Name="cbx_Role"
Width="240"
Margin="10,10,10,10" />
<TextBlock
Width="75"
Margin="20,15,0,10"
Text="过期时间:" />
<hc:DateTimePicker
x:Name="dt_ExpireTime"
Width="240"
Margin="10,10,10,10" />
</StackPanel>
<Grid Grid.Row="3">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="200" />
</Grid.ColumnDefinitions>
<Border
Margin="30"
BorderBrush="#FF4B85ED"
BorderThickness="1">
<ScrollViewer>
<hc:TextBox
Name="txt_License"
Height="200"
TextWrapping="Wrap" />
</ScrollViewer>
</Border>
<StackPanel Grid.Column="1" Orientation="Vertical">
<Button
Name="BtnCreate"
Margin="10,40,20,10"
Background="#FFEEBB00"
Click="BtnCreate_Click"
Content="生成License" />
<Button
Name="btn_Get"
Margin="10,10,20,10"
Click="btn_Get_Click"
Content="复制License" />
<Button
Name="btn_Check"
Margin="10,10,20,10"
Click="btn_Check_Click"
Content="验证License" />
<Button
Name="btn_ClearLicense"
Margin="10,10,20,10"
Click="btn_ClearLicense_Click"
Content="清空License" />
</StackPanel>
</Grid>
</Grid>
</hc:Window>