-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathMainWindow.xaml
106 lines (96 loc) · 4.21 KB
/
MainWindow.xaml
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
<Window x:Class="FileIconMOD.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"
xmlns:local="clr-namespace:FileIconMOD"
mc:Ignorable="d"
Title="小新图标修改工具"
Height="300"
Width="500"
ResizeMode="NoResize"
WindowStyle="SingleBorderWindow">
<Grid Background="AliceBlue">
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="*" />
<RowDefinition Height="*" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100" />
<ColumnDefinition Width="30" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<Label Grid.Row="0"
Content="文件类型"
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Margin="5"
FontSize="15"/>
<Label Grid.Row="1"
Content="图标路径"
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Margin="5"
FontSize="15"/>
<Label Grid.Row="2"
Content="打开程序"
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Margin="5"
FontSize="15"/>
<CheckBox x:Name="CheckBox_IconPath" Grid.Row="1" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" IsChecked="True"/>
<CheckBox x:Name="CheckBox_OpenExe" Grid.Row="2" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" IsChecked="True"/>
<Grid Grid.Row="0"
Grid.Column="2"
Margin="10">
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition Width="100"/>
<ColumnDefinition Width="30"/>
</Grid.ColumnDefinitions>
<TextBox Name="TextBox_FileType"
HorizontalContentAlignment="Left"
VerticalContentAlignment="Center"
AllowDrop="True"
PreviewDragOver="Text_FileType_PreviewDragOver"
PreviewDrop="Text_FileType_PreviewDrop" />
<Label Grid.Column="1"
Content="清除原配置"
HorizontalContentAlignment="Center"
VerticalContentAlignment="Center"
Margin="5"
FontSize="15"/>
<CheckBox x:Name="CheckBox_CleanCfg" Grid.Column="2" HorizontalAlignment="Center" VerticalAlignment="Center" IsChecked="False"/>
</Grid>
<TextBox Name="TextBox_IconPath"
Grid.Row="1"
Grid.Column="2"
Margin="10"
HorizontalContentAlignment="Left"
VerticalContentAlignment="Center"
PreviewDragOver="Text_FilePath_PreviewDragOver"
PreviewDrop="Text_FilePath_PreviewDrop"
LostKeyboardFocus="TextBox_FileType_LostFocus"
/>
<TextBox Name="TextBox_OpenExe"
Grid.Row="2"
Grid.Column="2"
Margin="10"
HorizontalContentAlignment="Left"
VerticalContentAlignment="Center"
PreviewDragOver="Text_FilePath_PreviewDragOver"
PreviewDrop="Text_FilePath_PreviewDrop"
TextChanged="TextBox_FilePath_TextChanged"
AllowDrop="True"
LostKeyboardFocus="TextBox_FileType_LostFocus"
/>
<Button Grid.Row="4"
Grid.ColumnSpan="3"
Height="25"
Width="70"
Content="修改图标"
Click="Button_Click" />
</Grid>
</Window>