A: 添加网络相关工具类 (NetUtils, SysInfoUtils) 及模型 (NetInfo)
A: 新增网络事件捕获及诊断功能支持 (TCP/UDP 连接、进程信息获取) U: 更新项目引用,Shell 添加对 Infrastructure 的依赖 U: 优化 WebPanel 消息处理逻辑,支持多种新指令 (GetNetInfo 等) U: 调整 ClientApp 中 WinDivertCommand.vue 的接口调用逻辑 D: 移除 Core 项目及相关配置
This commit is contained in:
1 parent
b14594ffb3
commit
0feeb00fae
11 files changed
+556
-29
No files matched your search
@@ -2,6 +2,7 @@ using System.Windows.Controls;
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
using System.Windows;
|
||||
using Infrastructure.utils;
|
||||
|
||||
namespace Shell.Views;
|
||||
|
||||
@@ -35,10 +36,29 @@ public partial class WebPanel : UserControl
|
||||
|
||||
Console.WriteLine(json);
|
||||
Console.WriteLine(msg?.Channel);
|
||||
if (msg?.Channel == "showMessage")
|
||||
|
||||
switch (msg?.Channel)
|
||||
{
|
||||
MessageBox.Show(msg.Payload?.Content ?? "无内容", msg.Payload?.Title ?? "提示");
|
||||
InitWebView1();
|
||||
case "showMessage":
|
||||
MessageBox.Show(msg.Payload?.Content ?? "无内容", msg.Payload?.Title ?? "提示");
|
||||
InitWebView1();
|
||||
break;
|
||||
case "GetNetInfo":
|
||||
NetUtils.GetNetInfo();
|
||||
break;
|
||||
case "GetProgramDiagnostics":
|
||||
var programDiagnostics = SysInfoUtils.GetProgramDiagnostics();
|
||||
Console.WriteLine(programDiagnostics);
|
||||
break;
|
||||
case "InspectProcess":
|
||||
SysInfoUtils.InspectProcess(23192);
|
||||
break;
|
||||
case "GetAllTcpConnections":
|
||||
NetUtils.GetAllTcpConnections();
|
||||
break;
|
||||
default:
|
||||
Console.WriteLine("没有任何函数被触发...");
|
||||
break;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user