|
|
|
@ -4,9 +4,7 @@
|
|
|
|
|
#include <WindowsConstants.au3> |
|
|
|
|
#include <WinAPI.au3> |
|
|
|
|
#NoTrayIcon |
|
|
|
|
|
|
|
|
|
Global $aArray = DriveGetDrive($DT_ALL), $sDisk, $iBtn11, $iBtn10, $iBtn7, $PathEr, $sDisk, $sDiskS, $UN11, $UN10x64, $UN10x86, $UN7x64, $UN7x86 |
|
|
|
|
|
|
|
|
|
For $i = 1 To $aArray[0] |
|
|
|
|
$aFileList = _FileListToArrayRec($aArray[$i] & "\WindowsESD", "NOT.DEL", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_NOSORT, $FLTAR_FULLPATH) |
|
|
|
|
If Not @error Then |
|
|
|
@ -15,7 +13,6 @@ For $i = 1 To $aArray[0]
|
|
|
|
|
ExitLoop |
|
|
|
|
EndIf |
|
|
|
|
Next |
|
|
|
|
|
|
|
|
|
For $i = 1 To $aArray[0] |
|
|
|
|
$aFileList = _FileListToArrayRec($aArray[$i] & "\efi\Paravis\Windows", "NOT.DEL", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_NOSORT, $FLTAR_FULLPATH) |
|
|
|
|
If Not @error Then |
|
|
|
@ -24,20 +21,17 @@ For $i = 1 To $aArray[0]
|
|
|
|
|
ExitLoop |
|
|
|
|
EndIf |
|
|
|
|
Next |
|
|
|
|
|
|
|
|
|
If $PathEr > 1 Then |
|
|
|
|
MsgBox(48, 'Предупреждение!', 'В системе больше одной папки с образами. Проверьте и удалите лишние (читаем ReadMe.txt). Система будет перезагружена.') |
|
|
|
|
Exit |
|
|
|
|
EndIf |
|
|
|
|
|
|
|
|
|
For $i = 1 To $aArray[0] |
|
|
|
|
$aFileList = _FileListToArrayRec($aArray[$i] & "\efi\Paravis\Boot\kitchen", "NOT.DEL", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_NOSORT, $FLTAR_FULLPATH) |
|
|
|
|
$aFileList = _FileListToArrayRec($aArray[$i] & "\efi\Paravis\Boot", "NOT.DEL", $FLTAR_FILES, $FLTAR_RECUR, $FLTAR_NOSORT, $FLTAR_FULLPATH) |
|
|
|
|
If Not @error Then |
|
|
|
|
$sDiskS = $aArray[$i] & "\efi\Paravis\Boot\" |
|
|
|
|
$sDiskS = $aArray[$i] & "\efi\Paravis\Boot" |
|
|
|
|
ExitLoop |
|
|
|
|
EndIf |
|
|
|
|
Next |
|
|
|
|
|
|
|
|
|
$ESD11 = $sDisk & "install_11.esd" |
|
|
|
|
$ESD10x64 = $sDisk & "install_10_x64.esd" |
|
|
|
|
$ESD10x86 = $sDisk & "install_10_x86.esd" |
|
|
|
@ -74,16 +68,13 @@ $OEM10x86 = " /m:" & $sDisk & "$OEM10x86$"
|
|
|
|
|
$OEM7x64 = " /m:" & $sDisk & "$OEM7x64$" |
|
|
|
|
$OEM7x86 = " /m:" & $sDisk & "$OEM7x86$" |
|
|
|
|
$setup = "X:\sources\setup.exe /installfrom:" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
If FileExists(@WindowsDir & "\SYSWOW64") Then |
|
|
|
|
RunWait($sDiskS & "src_x64.exe auto2") |
|
|
|
|
RunWait($sDiskS & "\src_x64.exe auto2") |
|
|
|
|
_x64() |
|
|
|
|
Else |
|
|
|
|
RunWait($sDiskS & "src_x86.exe auto2") |
|
|
|
|
RunWait($sDiskS & "\src_x86.exe auto2") |
|
|
|
|
_x86() |
|
|
|
|
EndIf |
|
|
|
|
|
|
|
|
|
Func _x86() |
|
|
|
|
$detect_efi = EnvGet("firmware_type") |
|
|
|
|
If $detect_efi = "Legacy" Then |
|
|
|
@ -102,9 +93,7 @@ Func _x86()
|
|
|
|
|
$iBtnR = GUICtrlCreateButton("Перезагрузка", 5, 145, 350, 40) |
|
|
|
|
GUICtrlSetFont(-1, 16, 500, 0, $font) |
|
|
|
|
GUISetState() |
|
|
|
|
|
|
|
|
|
_checkesd86() |
|
|
|
|
|
|
|
|
|
While 1 |
|
|
|
|
Switch GUIGetMsg() |
|
|
|
|
Case $GUI_EVENT_CLOSE |
|
|
|
@ -119,7 +108,7 @@ Func _x86()
|
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnTC |
|
|
|
|
GUISetState(@SW_HIDE) |
|
|
|
|
RunWait($sDiskS & 'kitchen\TotalCommander\TOTALCMD.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
RunWait($sDiskS & '\TotalCommander\TOTALCMD.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnR |
|
|
|
|
Exit |
|
|
|
@ -143,7 +132,6 @@ Func _x86()
|
|
|
|
|
$iBtnR = GUICtrlCreateButton("Перезагрузка", 5, 105, 350, 40) |
|
|
|
|
GUICtrlSetFont(-1, 16, 500, 0, $font) |
|
|
|
|
GUISetState() |
|
|
|
|
|
|
|
|
|
While 1 |
|
|
|
|
Switch GUIGetMsg() |
|
|
|
|
Case $GUI_EVENT_CLOSE |
|
|
|
@ -154,7 +142,7 @@ Func _x86()
|
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnTC |
|
|
|
|
GUISetState(@SW_HIDE) |
|
|
|
|
RunWait($sDiskS & 'kitchen\TotalCommander\TOTALCMD.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
RunWait($sDiskS & '\TotalCommander\TOTALCMD.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnR |
|
|
|
|
Exit |
|
|
|
@ -162,7 +150,6 @@ Func _x86()
|
|
|
|
|
WEnd |
|
|
|
|
EndIf |
|
|
|
|
EndFunc |
|
|
|
|
|
|
|
|
|
Func _x64() |
|
|
|
|
$hGUI = GUICreate("Windows Setup by Paravis", 410, 250, -1, -1, $WS_POPUP, $WS_EX_LAYERED) |
|
|
|
|
GUISetBkColor(0xABCDEF) |
|
|
|
@ -181,9 +168,7 @@ Func _x64()
|
|
|
|
|
$iBtnR = GUICtrlCreateButton("Перезагрузка", 5, 185, 350, 40) |
|
|
|
|
GUICtrlSetFont(-1, 16, 500, 0, $font) |
|
|
|
|
GUISetState() |
|
|
|
|
|
|
|
|
|
_checkesd64() |
|
|
|
|
|
|
|
|
|
While 1 |
|
|
|
|
Switch GUIGetMsg() |
|
|
|
|
Case $GUI_EVENT_CLOSE |
|
|
|
@ -202,14 +187,13 @@ Func _x64()
|
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnTC |
|
|
|
|
GUISetState(@SW_HIDE) |
|
|
|
|
RunWait($sDiskS & 'kitchen\TotalCommander\TOTALCMD64.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
RunWait($sDiskS & '\TotalCommander\TOTALCMD64.EXE /I="%%COMMANDER_PATH%%\tcmdmain.ini"') |
|
|
|
|
GUISetState(@SW_SHOW) |
|
|
|
|
Case $iBtnR |
|
|
|
|
Exit |
|
|
|
|
EndSwitch |
|
|
|
|
WEnd |
|
|
|
|
EndFunc |
|
|
|
|
|
|
|
|
|
Func _checkesd64() |
|
|
|
|
If Not FileExists($sDisk & "install_11.esd") Then |
|
|
|
|
GUICtrlSetState($iBtn11, $GUI_DISABLE) |
|
|
|
@ -221,7 +205,6 @@ Func _checkesd64()
|
|
|
|
|
GUICtrlSetState($iBtn7, $GUI_DISABLE) |
|
|
|
|
EndIf |
|
|
|
|
EndFunc |
|
|
|
|
|
|
|
|
|
Func _checkesd86() |
|
|
|
|
If Not FileExists($sDisk & "install_10_x86.esd") Then |
|
|
|
|
GUICtrlSetState($iBtn10, $GUI_DISABLE) |
|
|
|
|