259ce3dd11
添加 IAppRestartService 接口及其实现 AppRestartService,用于插件系统调用应用重启功能 将原 StartupPage 中的重启逻辑提取到 AppRestartHelper 工具类中 在 App.xaml.cs 中注册 AppRestartService 供插件使用
22 lines
385 B
C#
22 lines
385 B
C#
using System;
|
|
|
|
namespace Ink_Canvas.Plugins
|
|
{
|
|
public interface IAppRestartService
|
|
{
|
|
bool IsRunningAsAdmin { get; }
|
|
|
|
void RestartApp(bool asAdmin);
|
|
|
|
void RestartWithCurrentPrivileges();
|
|
|
|
void RestartAsAdmin();
|
|
|
|
void RestartAsNormal();
|
|
|
|
void SwitchToUIATopMostAndRestart();
|
|
|
|
void SwitchToNormalTopMostAndRestart();
|
|
}
|
|
}
|