2004-11-27 14:50:43 +00:00
|
|
|
;NSIS Modern User Interface
|
2002-11-08 21:08:27 +00:00
|
|
|
;Basic Example Script
|
2002-10-07 19:59:01 +00:00
|
|
|
;Written by Joost Verburg
|
|
|
|
|
2003-05-25 20:21:21 +00:00
|
|
|
;--------------------------------
|
|
|
|
;Include Modern UI
|
2002-11-04 11:19:21 +00:00
|
|
|
|
2008-01-27 17:24:40 +00:00
|
|
|
!include "MUI2.nsh"
|
2002-10-07 19:59:01 +00:00
|
|
|
|
|
|
|
;--------------------------------
|
2004-02-06 23:01:57 +00:00
|
|
|
;General
|
2002-10-07 19:59:01 +00:00
|
|
|
|
2004-02-06 23:01:57 +00:00
|
|
|
;Name and file
|
2004-11-27 14:50:43 +00:00
|
|
|
Name "Modern UI Test"
|
2002-12-24 22:38:06 +00:00
|
|
|
OutFile "Basic.exe"
|
|
|
|
|
2004-01-07 19:21:00 +00:00
|
|
|
;Default installation folder
|
2008-02-04 01:35:09 +00:00
|
|
|
InstallDir "$LOCALAPPDATA\Modern UI Test"
|
2003-03-09 22:38:13 +00:00
|
|
|
|
2004-01-07 19:21:00 +00:00
|
|
|
;Get installation folder from registry if available
|
2003-09-09 16:06:37 +00:00
|
|
|
InstallDirRegKey HKCU "Software\Modern UI Test" ""
|
2002-12-24 22:38:06 +00:00
|
|
|
|
2008-02-04 01:35:09 +00:00
|
|
|
;Request application privileges for Windows Vista
|
2008-01-27 17:24:40 +00:00
|
|
|
RequestExecutionLevel user
|
|
|
|
|
2003-09-04 18:42:21 +00:00
|
|
|
;--------------------------------
|
2003-10-08 15:28:44 +00:00
|
|
|
;Interface Settings
|
2003-09-04 18:42:21 +00:00
|
|
|
|
|
|
|
!define MUI_ABORTWARNING
|
|
|
|
|
2002-12-24 22:38:06 +00:00
|
|
|
;--------------------------------
|
2003-05-25 20:21:21 +00:00
|
|
|
;Pages
|
2002-12-24 22:38:06 +00:00
|
|
|
|
2005-06-19 21:39:04 +00:00
|
|
|
!insertmacro MUI_PAGE_LICENSE "${NSISDIR}\Docs\Modern UI\License.txt"
|
2003-05-25 20:21:21 +00:00
|
|
|
!insertmacro MUI_PAGE_COMPONENTS
|
|
|
|
!insertmacro MUI_PAGE_DIRECTORY
|
|
|
|
!insertmacro MUI_PAGE_INSTFILES
|
2002-12-06 21:56:28 +00:00
|
|
|
|
2003-05-25 20:21:21 +00:00
|
|
|
!insertmacro MUI_UNPAGE_CONFIRM
|
|
|
|
!insertmacro MUI_UNPAGE_INSTFILES
|
2002-12-06 21:56:28 +00:00
|
|
|
|
2002-12-24 22:38:06 +00:00
|
|
|
;--------------------------------
|
|
|
|
;Languages
|
|
|
|
|
2002-11-04 16:40:35 +00:00
|
|
|
!insertmacro MUI_LANGUAGE "English"
|
2002-10-07 19:59:01 +00:00
|
|
|
|
|
|
|
;--------------------------------
|
|
|
|
;Installer Sections
|
|
|
|
|
2003-06-10 19:32:00 +00:00
|
|
|
Section "Dummy Section" SecDummy
|
2002-10-07 19:59:01 +00:00
|
|
|
|
2003-12-18 14:00:33 +00:00
|
|
|
SetOutPath "$INSTDIR"
|
|
|
|
|
2004-02-06 23:01:57 +00:00
|
|
|
;ADD YOUR OWN FILES HERE...
|
2003-12-18 14:00:33 +00:00
|
|
|
|
2004-01-07 19:21:00 +00:00
|
|
|
;Store installation folder
|
2003-12-18 14:00:33 +00:00
|
|
|
WriteRegStr HKCU "Software\Modern UI Test" "" $INSTDIR
|
|
|
|
|
|
|
|
;Create uninstaller
|
|
|
|
WriteUninstaller "$INSTDIR\Uninstall.exe"
|
2002-10-07 19:59:01 +00:00
|
|
|
|
|
|
|
SectionEnd
|
|
|
|
|
|
|
|
;--------------------------------
|
2002-11-04 11:19:21 +00:00
|
|
|
;Descriptions
|
2002-10-07 19:59:01 +00:00
|
|
|
|
2004-01-07 19:21:00 +00:00
|
|
|
;Language strings
|
2003-06-10 19:32:00 +00:00
|
|
|
LangString DESC_SecDummy ${LANG_ENGLISH} "A test section."
|
2003-05-25 20:21:21 +00:00
|
|
|
|
2004-01-07 19:21:00 +00:00
|
|
|
;Assign language strings to sections
|
2003-09-04 18:42:21 +00:00
|
|
|
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
|
2003-06-10 19:32:00 +00:00
|
|
|
!insertmacro MUI_DESCRIPTION_TEXT ${SecDummy} $(DESC_SecDummy)
|
2003-09-04 18:42:21 +00:00
|
|
|
!insertmacro MUI_FUNCTION_DESCRIPTION_END
|
2004-01-07 19:21:00 +00:00
|
|
|
|
2002-10-07 19:59:01 +00:00
|
|
|
;--------------------------------
|
|
|
|
;Uninstaller Section
|
|
|
|
|
|
|
|
Section "Uninstall"
|
|
|
|
|
2004-02-06 23:01:57 +00:00
|
|
|
;ADD YOUR OWN FILES HERE...
|
2003-12-18 14:00:33 +00:00
|
|
|
|
2002-10-07 19:59:01 +00:00
|
|
|
Delete "$INSTDIR\Uninstall.exe"
|
|
|
|
|
2003-12-18 14:00:33 +00:00
|
|
|
RMDir "$INSTDIR"
|
|
|
|
|
|
|
|
DeleteRegKey /ifempty HKCU "Software\Modern UI Test"
|
|
|
|
|
2002-11-03 13:21:09 +00:00
|
|
|
SectionEnd
|