新增应用程序图标并优化界面与匹配逻辑
- 增加 复制.ico 作为应用图标,并在项目文件中配置 ApplicationIcon。 - 修正 MatchFolderName 数字编号截取索引,保证匹配准确。 - 调整主窗口高度为 645,优化界面体验。 - LogTextBox 允许编辑(去除 IsReadOnly)。 - 处理单个料号时回车后自动聚焦输入框,提升操作流畅度。 - 代码格式优化,提升可读性。
This commit is contained in:
@@ -8,6 +8,11 @@
|
||||
<UseWPF>true</UseWPF>
|
||||
<UseWindowsForms>true</UseWindowsForms>
|
||||
<Platforms>AnyCPU;x86</Platforms>
|
||||
<ApplicationIcon>复制.ico</ApplicationIcon>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Content Include="复制.ico" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
@@ -23,12 +23,12 @@ namespace CopyRou
|
||||
return false;
|
||||
|
||||
// 从第4个字符开始匹配数字编号(索引3)
|
||||
var numInName = folderNameLower.Substring(3, numLength);
|
||||
var numInName = folderNameLower.Substring(4, numLength);
|
||||
if (numInName != numPart.ToLower())
|
||||
return false;
|
||||
|
||||
// 检查版本部分
|
||||
var versionInName = folderNameLower.Substring(3 + numLength);
|
||||
var versionInName = folderNameLower.Substring(4 + numLength);
|
||||
return versionInName.StartsWith(versionPart.ToLower());
|
||||
}
|
||||
|
||||
|
||||
@@ -7,9 +7,9 @@
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
Title="ROU文件复制工具"
|
||||
Width="586"
|
||||
Height="631"
|
||||
Height="645"
|
||||
MinWidth="586"
|
||||
MinHeight="631"
|
||||
MinHeight="645"
|
||||
mc:Ignorable="d">
|
||||
<Grid Margin="10">
|
||||
<Grid.RowDefinitions>
|
||||
@@ -50,7 +50,6 @@
|
||||
Height="60"
|
||||
Margin="5"
|
||||
AcceptsReturn="True"
|
||||
IsReadOnly="True"
|
||||
TextWrapping="Wrap"
|
||||
VerticalScrollBarVisibility="Auto" />
|
||||
<Button
|
||||
|
||||
@@ -179,6 +179,7 @@ namespace CopyRou
|
||||
if (e.Key == System.Windows.Input.Key.Enter)
|
||||
{
|
||||
ProcessSingleCode();
|
||||
SingleCodeTextBox.Focus();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user