client: Windows 客户端(WinUI3 壳 + agent-core;调试用 Electron 壳存档);localserver token 改为常数时间比较
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Windows.Input;
|
||||
|
||||
namespace EveryPublish.Client.Services;
|
||||
|
||||
/// <summary>极简 ICommand 实现(托盘命令用,免 CommunityToolkit 依赖)</summary>
|
||||
public class SimpleCommand : ICommand
|
||||
{
|
||||
private readonly Action _action;
|
||||
|
||||
public SimpleCommand(Action action)
|
||||
{
|
||||
_action = action;
|
||||
}
|
||||
|
||||
public event EventHandler? CanExecuteChanged { add { } remove { } }
|
||||
|
||||
public bool CanExecute(object? parameter) => true;
|
||||
|
||||
public void Execute(object? parameter) => _action();
|
||||
}
|
||||
Reference in New Issue
Block a user