2002-11-08 17:30:29 +00:00
|
|
|
!verbose 3
|
|
|
|
!include "${NSISDIR}\Examples\WinMessages.nsh"
|
|
|
|
!verbose 4
|
|
|
|
|
|
|
|
Name "StartMenu.dll test"
|
|
|
|
|
|
|
|
OutFile "StartMenu Test.exe"
|
|
|
|
|
|
|
|
XPStyle on
|
|
|
|
|
|
|
|
Page directory
|
|
|
|
DirText "This installer will create some shortcuts to MakeNSIS in the start menu.$\nFor this it needs NSIS's folder path." \
|
|
|
|
"Please specify the path in which you have installed NSIS:"
|
|
|
|
InstallDir "${NSISDIR}"
|
|
|
|
Function .onVerifyInstDir
|
|
|
|
IfFileExists $INSTDIR\makensis.exe +2
|
|
|
|
Abort
|
|
|
|
FunctionEnd
|
|
|
|
|
|
|
|
Page custom StartMenuGroupSelect
|
|
|
|
Function StartMenuGroupSelect
|
|
|
|
SendMessage $HWNDPARENT ${WM_SETTEXT} 0 "STR:StartMenu.dll test Setup: Start Menu Folder"
|
|
|
|
|
|
|
|
StartMenu::Select /autoadd "StartMenu.dll test"
|
2002-11-08 23:25:08 +00:00
|
|
|
Pop $R1
|
2002-11-08 17:30:29 +00:00
|
|
|
|
2002-11-08 23:25:08 +00:00
|
|
|
StrCpy $R2 $R1 5
|
|
|
|
StrCmp $R2 "error" 0 +3
|
2002-11-08 17:30:29 +00:00
|
|
|
; error
|
2002-11-08 23:25:08 +00:00
|
|
|
MessageBox MB_OK $R1
|
2002-11-08 17:30:29 +00:00
|
|
|
Return
|
2002-11-08 23:25:08 +00:00
|
|
|
StrCmp $R1 "cancel" 0 +2
|
2002-11-08 17:30:29 +00:00
|
|
|
Quit
|
2002-11-08 23:25:08 +00:00
|
|
|
StrCmp $R1 "back" 0 +2
|
2002-11-08 17:30:29 +00:00
|
|
|
Abort
|
2002-11-08 23:25:08 +00:00
|
|
|
StrCpy $R0 $R1 ; got the dir
|
2002-11-08 17:30:29 +00:00
|
|
|
FunctionEnd
|
|
|
|
|
|
|
|
Page instfiles
|
|
|
|
Section
|
|
|
|
CreateDirectory $SMPROGRAMS\$R0
|
|
|
|
CreateShortCut $SMPROGRAMS\$R0\MakeNSIS.lnk $INSTDIR\makensis.exe
|
|
|
|
|
|
|
|
SetShellVarContext All
|
|
|
|
CreateDirectory $SMPROGRAMS\$R0
|
|
|
|
CreateShortCut "$SMPROGRAMS\$R0\All users MakeNSIS.lnk" $INSTDIR\makensis.exe
|
|
|
|
SectionEnd
|