feat: Migrate more PowerShell calls to Rust implementation

This commit is contained in:
xkeyC
2025-12-05 11:06:54 +08:00
parent f6676ed3d8
commit 62b8718dbd
16 changed files with 1377 additions and 357 deletions

View File

@@ -22,7 +22,6 @@ import 'package:window_manager/window_manager.dart';
import 'api/analytics.dart';
import 'api/api.dart';
import 'common/conf/url_conf.dart';
import 'common/helper/system_helper.dart';
import 'common/io/rs_http.dart';
import 'common/rust/frb_generated.dart';
import 'common/rust/api/win32_api.dart' as win32;
@@ -148,16 +147,6 @@ class AppGlobalModel extends _$AppGlobalModel {
exit(0);
}
// init powershell
if (Platform.isWindows) {
try {
await SystemHelper.initPowershellPath();
dPrint("---- Powershell init -----");
} catch (e) {
dPrint("powershell init failed : $e");
}
}
// get windows info
WindowsDeviceInfo? windowsDeviceInfo;
try {