feat: NSIS 中文安装器(年糕历险记-Setup-v0.1.0.exe 实际构建+静默安装验证)、菜单鼠标可见性修复、首页 UI 原版复刻(土质背景/原版按钮/splash/版本角标)、全 goroutine 崩溃兜底

This commit is contained in:
NianGao Dev
2026-08-16 06:46:25 +08:00
parent 854440216f
commit 6dd5a8122a
434 changed files with 63991 additions and 106 deletions

View File

@@ -0,0 +1,107 @@
!include LogicLib.nsh
!include nsDialogs.nsh
!include WinMessages.nsh
Name "nsDialogs Timer Example"
OutFile "nsDialogs Timer Example.exe"
XPStyle on
RequestExecutionLevel user
Var DIALOG
Var TEXT
Var PROGBAR
Var PROGBAR2
Var PROGBAR3
Var BUTTON
Var BUTTON2
Page custom nsDialogsPage
!pragma warning disable 8000 ; "Page instfiles not used, no sections will be executed!"
Function OnTimer
SendMessage $PROGBAR ${PBM_GETPOS} 0 0 $1
${If} $1 = 100
SendMessage $PROGBAR ${PBM_SETPOS} 0 0
${Else}
SendMessage $PROGBAR ${PBM_DELTAPOS} 10 0
${EndIf}
FunctionEnd
Function OnTimer2
SendMessage $PROGBAR2 ${PBM_GETPOS} 0 0 $1
${If} $1 = 100
SendMessage $PROGBAR2 ${PBM_SETPOS} 0 0
${Else}
SendMessage $PROGBAR2 ${PBM_DELTAPOS} 5 0
${EndIf}
FunctionEnd
Function OnTimer3
SendMessage $PROGBAR3 ${PBM_GETPOS} 0 0 $1
${If} $1 >= 100
${NSD_KillTimer} OnTimer3
MessageBox MB_OK "Timer 3 killed"
${Else}
SendMessage $PROGBAR3 ${PBM_DELTAPOS} 2 0
${EndIf}
FunctionEnd
Function OnClick
Pop $0
${NSD_KillTimer} OnTimer
FunctionEnd
Function OnClick2
Pop $0
${NSD_KillTimer} OnTimer2
FunctionEnd
Function nsDialogsPage
nsDialogs::Create 1018
Pop $DIALOG
${NSD_CreateLabel} 0u 0u 100% 9u "nsDialogs timer example"
Pop $TEXT
${NSD_CreateProgressBar} 0u 10u 100% 12u ""
Pop $PROGBAR
${NSD_CreateButton} 0u 25u 100u 14u "Kill Timer 1"
Pop $BUTTON
${NSD_OnClick} $BUTTON OnClick
${NSD_CreateProgressBar} 0u 52u 100% 12u ""
Pop $PROGBAR2
SendMessage $PROGBAR2 ${PBM_SETBARCOLOR} 0 0x0000FF ; No visual styles
SendMessage $PROGBAR2 ${PBM_SETSTATE} ${PBST_ERROR} 0 ; Vista+
${NSD_CreateButton} 0u 67u 100u 14u "Kill Timer 2"
Pop $BUTTON2
${NSD_OnClick} $BUTTON2 OnClick2
${NSD_CreateProgressBar} 0u 114u 100% 12u ""
Pop $PROGBAR3
${NSD_CreateTimer} OnTimer 1000
${NSD_CreateTimer} OnTimer2 100
${NSD_CreateTimer} OnTimer3 200
nsDialogs::Show
FunctionEnd
Section
SectionEnd