mirror of
https://github.com/zs-yg/kortapp-z.git
synced 2025-12-06 16:10:42 +08:00
Add files via upload
This commit is contained in:
@@ -16,6 +16,9 @@
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="help.txt" />
|
||||
<None Include="resource\NetWorkManager\*">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
<None Include="resource\*.exe">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
@@ -33,4 +36,8 @@
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="ZXing.Net" Version="0.16.8" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
44
MainForm.cs
44
MainForm.cs
@@ -566,6 +566,46 @@ namespace AppStore
|
||||
passwordGeneratorCard.UpdateDisplay();
|
||||
flowPanel.Controls.Add(passwordGeneratorCard);
|
||||
|
||||
// 端口检测工具卡片
|
||||
var portCheckerCard = new ToolCard();
|
||||
portCheckerCard.ToolName = "端口检测";
|
||||
try
|
||||
{
|
||||
string iconPath = Path.Combine(Application.StartupPath, "img", "resource", "png", "system_info.png");
|
||||
if (File.Exists(iconPath))
|
||||
{
|
||||
portCheckerCard.ToolIcon = Image.FromFile(iconPath);
|
||||
}
|
||||
else
|
||||
{
|
||||
portCheckerCard.ToolIcon = SystemIcons.Shield.ToBitmap();
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
portCheckerCard.ToolIcon = SystemIcons.Shield.ToBitmap();
|
||||
}
|
||||
portCheckerCard.ToolCardClicked += (s, e) => {
|
||||
try {
|
||||
string toolPath = Path.Combine(Application.StartupPath, "resource", "NetWorkManager", "NetWorkManager.exe");
|
||||
string absolutePath = Path.GetFullPath(toolPath);
|
||||
if (File.Exists(absolutePath)) {
|
||||
Process.Start(new ProcessStartInfo {
|
||||
FileName = absolutePath,
|
||||
WorkingDirectory = Path.GetDirectoryName(absolutePath)
|
||||
});
|
||||
} else {
|
||||
MessageBox.Show($"端口检测工具未找到,请确保已正确安装。路径: {absolutePath}", "错误",
|
||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
MessageBox.Show($"启动端口检测工具失败: {ex.Message}", "错误",
|
||||
MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
};
|
||||
portCheckerCard.UpdateDisplay();
|
||||
flowPanel.Controls.Add(portCheckerCard);
|
||||
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
@@ -780,7 +820,7 @@ namespace AppStore
|
||||
|
||||
flowPanel.Controls.Add(CreateAppCard(
|
||||
"Msys2",
|
||||
"https://ghproxy.net/https://github.com/msys2/msys2-installer/releases/download/2025-02-21/msys2-x86_64-20250221.exe",
|
||||
"https://hub.gitmirror.com/https://github.com/msys2/msys2-installer/releases/download/2025-02-21/msys2-x86_64-20250221.exe",
|
||||
"img/png/MSYS2.png"));
|
||||
|
||||
flowPanel.Controls.Add(CreateAppCard(
|
||||
@@ -880,7 +920,7 @@ namespace AppStore
|
||||
|
||||
flowPanel.Controls.Add(CreateAppCard(
|
||||
"frp",
|
||||
"https://ghproxy.net/https://github.com/fatedier/frp/releases/download/v0.62.1/frp_0.62.1_windows_amd64.zip",
|
||||
"https://hub.gitmirror.com/https://github.com/fatedier/frp/releases/download/v0.62.1/frp_0.62.1_windows_amd64.zip",
|
||||
""));
|
||||
|
||||
flowPanel.Controls.Add(CreateAppCard(
|
||||
|
||||
Reference in New Issue
Block a user