#Update 开机自启兼容配置改为win7 优化联机是否成功的判断方式

#Update 开机自启兼容配置改为win7 优化联机是否成功的判断方式

优化联机是否成功的判断方式

版本号更新->1.5.3
This commit is contained in:
黑先森
2025-11-18 16:42:58 +08:00
parent 94968401fc
commit 9f63d9bf2e
8 changed files with 105 additions and 194 deletions
+1 -1
View File
@@ -1178,7 +1178,7 @@ checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555"
[[package]]
name = "easytier-game"
version = "1.5.1"
version = "1.5.3"
dependencies = [
"hashbrown 0.15.5",
"log",
+1 -1
View File
@@ -1,6 +1,6 @@
[package]
name = "easytier-game"
version = "1.5.2"
version = "1.5.3"
homepage = "https://github.com/EasyTier/EasyTier"
repository = "https://github.com/EasyTier/EasytierGame"
description = "A simple network initiator based on Easytier"
+2 -1
View File
@@ -875,6 +875,7 @@ fn autostart(enabled: bool) -> std::result::Result<(), Box<dyn std::error::Error
exec_action.SetPath(&BSTR::from(exe_path))?;
exec_action.SetArguments(&BSTR::from("--task-auto-start"))?;
// 设置任务权限为当前用户
let principal = task_definition.Principal()?;
principal.SetUserId(&BSTR::from(whoami::username().as_str()))?;
principal.SetLogonType(TASK_LOGON_INTERACTIVE_TOKEN)?;
@@ -883,7 +884,7 @@ fn autostart(enabled: bool) -> std::result::Result<(), Box<dyn std::error::Error
// 设置任务设置
let settings = task_definition.Settings()?;
settings.SetEnabled(VARIANT_BOOL::from(true))?;
settings.SetCompatibility(TASK_COMPATIBILITY_V2)?; // Windows 7
settings.SetCompatibility(TASK_COMPATIBILITY_V2_1)?; // Windows 7
settings.SetStartWhenAvailable(VARIANT_BOOL::from(true))?;
// settings.SetHidden(VARIANT_BOOL::from(true))?; // 注释掉让任务可见
settings.SetExecutionTimeLimit(&BSTR::from("PT0S"))?;
+2 -2
View File
@@ -1,7 +1,7 @@
{
"$schema": "../node_modules/@tauri-apps/cli/config.schema.json",
"productName": "easytier-game",
"version": "1.5.2",
"version": "1.5.3",
"identifier": "com.tauri.easytier-game",
"build": {
@@ -12,7 +12,7 @@
"app": {
"windows": [
{
"title": "easytier-game 1.5.2",
"title": "easytier-game 1.5.3",
"label": "main",
"minWidth": 340,
"width": 340,