From c2579fbae69f84b62a3573f16bd7c42fdd92e18d Mon Sep 17 00:00:00 2001 From: xrgzs Date: Mon, 29 Apr 2024 10:50:04 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=20=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E6=A3=80=E6=B5=8B=E8=A7=A6=E6=91=B8=E8=AE=BE=E5=A4=87=E5=B9=B6?= =?UTF-8?q?=E5=AF=BC=E5=85=A5=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- osc/themerec/themerec.bat | 41 +++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 17 deletions(-) diff --git a/osc/themerec/themerec.bat b/osc/themerec/themerec.bat index 0da3559..568d835 100644 --- a/osc/themerec/themerec.bat +++ b/osc/themerec/themerec.bat @@ -2,31 +2,36 @@ chcp 936 > nul cd /d "%~dp0" title 主题恢复 -if exist "%SystemDrive%\Windows\Setup\xrsysnotheme.txt" ( - exit -) +if exist "%SystemDrive%\Windows\Setup\xrsysnotheme.txt" exit + +set istouch= +set osver=0 +ver | find /i "5.1." > nul && set osver=1 +ver | find /i "6.0." > nul && set osver=2 +ver | find /i "6.1." > nul && set osver=2 +ver | find /i "6.2." > nul && set osver=3 +ver | find /i "6.3." > nul && set osver=3 +ver | find /i "6.4." > nul && set osver=4 +ver | find /i "10.0." > nul && set osver=4 + if exist "%SystemDrive%\Windows\Setup\xrsyswall.jpg" ( copy /y "%SystemDrive%\Windows\Setup\xrsyswall.jpg" wallpaper.jpg ) if exist "%SystemDrive%\Windows\Setup\Set\wallpaper.jpg" ( copy /y "%SystemDrive%\Windows\Setup\Set\wallpaper.jpg" wallpaper.jpg ) -if exist "%SystemDrive%\Windows\Setup\zjsoftseewo.txt" call :iwb -if exist "%SystemDrive%\Windows\Setup\zjsofthite.txt" call :iwb +if exist "%SystemDrive%\Windows\Setup\zjsoftseewo.txt" call :touch +if exist "%SystemDrive%\Windows\Setup\zjsofthite.txt" call :touch if exist "%SystemDrive%\Windows\Setup\zjsoftwenxiang.txt" ( regedit /s touchwx.reg - call :iwb + call :touch ) -::系统版本判断 -set osver=0 -::上面一行可根据系统情况手动填写系统版本,并将下面全部注释掉 -ver | find /i "5.1." > nul && set osver=1 -ver | find /i "6.0." > nul && set osver=2 -ver | find /i "6.1." > nul && set osver=2 -ver | find /i "6.2." > nul && set osver=3 -ver | find /i "6.3." > nul && set osver=3 -ver | find /i "6.4." > nul && set osver=4 -ver | find /i "10.0." > nul && set osver=4 + +if %osver% GEQ 3 ( + for /f "tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\Tablet PC" /v "Devic +eKind"') do if /i not "%%a"=="0x0" call :touch +) + :main if exist "%SystemDrive%\Windows\Setup\xrsysdark.txt" ( @@ -62,11 +67,13 @@ if exist wallpaper.jpg ( reg delete "HKCU\Control Panel\Desktop" /f /v "Wallpaper.PECMD" exit -:iwb +:touch +if defined istouch goto :EOF if exist "%ProgramW6432%" ( PinToTaskbar.exe /pin "%SystemDrive%\Windows\System32\osk.exe" ) else ( %PECMD% PINT "%SystemDrive%\Windows\System32\osk.exe",TaskBand ) regedit /s touch.reg +set istouch=1 goto :EOF \ No newline at end of file