Updated macro system
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1143 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
4bb4a97bd2
commit
6f44af19b3
3 changed files with 28 additions and 34 deletions
|
@ -92,7 +92,6 @@ FunctionEnd
|
|||
|
||||
Function .onNextPage
|
||||
|
||||
!insertmacro MUI_NEXTPAGE_OUTER
|
||||
!insertmacro MUI_NEXTPAGE SetPage
|
||||
|
||||
FunctionEnd
|
||||
|
@ -170,7 +169,6 @@ SectionEnd
|
|||
|
||||
Function un.onNextPage
|
||||
|
||||
!insertmacro MUI_NEXTPAGE_OUTER
|
||||
!insertmacro MUI_NEXTPAGE un.SetPage
|
||||
|
||||
FunctionEnd
|
||||
|
|
|
@ -75,7 +75,6 @@ SectionEnd
|
|||
Function .onInit
|
||||
|
||||
;Init InstallOptions
|
||||
!insertmacro MUI_INSTALLOPTIONS_INIT ;Call this when using no plugins before using Install Options (init plugin system)
|
||||
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "iniA.ini"
|
||||
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "iniB.ini"
|
||||
!insertmacro MUI_INSTALLOPTIONS_EXTRACT "iniC.ini"
|
||||
|
@ -105,7 +104,6 @@ FunctionEnd
|
|||
|
||||
Function .onNextPage
|
||||
|
||||
!insertmacro MUI_NEXTPAGE_OUTER
|
||||
!insertmacro MUI_INSTALLOPTIONS_NEXTPAGE
|
||||
!insertmacro MUI_NEXTPAGE SetPage
|
||||
|
||||
|
@ -158,7 +156,7 @@ Function SetPage
|
|||
WriteIniStr "$PLUGINSDIR\iniB.ini" "Settings" "CancelConfirm" "Are you sure you want to quit ${NAME} Setup?"
|
||||
WriteIniStr "$PLUGINSDIR\iniB.ini" "Settings" "CancelConfirmCaption" "${NAME} ${VERSION} Setup"
|
||||
WriteIniStr "$PLUGINSDIR\iniB.ini" "Settings" "CancelConfirmIcon" "MB_ICONWARNING"
|
||||
!insertmacro MUI_INSTALLOPTIONS_SHOW 6 "iniC.ini" "" ""
|
||||
!insertmacro MUI_INSTALLOPTIONS_SHOW 6 "iniC.ini" "" "" ;Next/previous page is no IO page
|
||||
!insertmacro MUI_PAGE_STOP 6
|
||||
|
||||
!insertmacro MUI_PAGE_START 7
|
||||
|
@ -212,7 +210,6 @@ SectionEnd
|
|||
|
||||
Function un.onNextPage
|
||||
|
||||
!insertmacro MUI_NEXTPAGE_OUTER
|
||||
!insertmacro MUI_NEXTPAGE un.SetPage
|
||||
|
||||
FunctionEnd
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
;Modern UI Header File version 1.19h
|
||||
;Modern UI Header File version 1.19i
|
||||
;Written by Joost Verburg
|
||||
|
||||
;See Example.nsi & Multilanguage.nsi for an example of usage
|
||||
|
@ -10,6 +10,9 @@
|
|||
!define IO_DIRECTION_NEXT 1
|
||||
!define IO_DIRECTION_PREV 2
|
||||
|
||||
!define IO_INITPLUGINS "Call Initialize_____Plugins"
|
||||
!define IO_UNINITPLUGINS "Call un.Initialize_____Plugins"
|
||||
|
||||
!macro MUI_INTERFACE UI ICON UNICON CHECKS PROGRESSBAR
|
||||
|
||||
;User interface
|
||||
|
@ -72,14 +75,14 @@
|
|||
|
||||
!macroend
|
||||
|
||||
!macro MUI_NEXTPAGE_OUTER
|
||||
|
||||
Push ${TEMP1}
|
||||
Push ${TEMP2}
|
||||
!macro MUI_NEXTPAGE CALL
|
||||
|
||||
;Set backgrounds & fonts for the outer dialog (only once)
|
||||
StrCmp ${CURRENTPAGE} "" "" no_first_run
|
||||
|
||||
|
||||
Push ${TEMP1}
|
||||
Push ${TEMP2}
|
||||
|
||||
GetDlgItem ${TEMP1} $HWNDPARENT 1037
|
||||
CreateFont ${TEMP2} "Tahoma" 10 700
|
||||
SendMessage ${TEMP1} ${WM_SETFONT} ${TEMP2} 0
|
||||
|
@ -93,20 +96,16 @@
|
|||
|
||||
GetDlgItem ${TEMP1} $HWNDPARENT 1039
|
||||
SetStaticBkColor ${TEMP1} 0x00FFFFFF
|
||||
|
||||
no_first_run:
|
||||
|
||||
Pop ${TEMP2}
|
||||
Pop ${TEMP1}
|
||||
|
||||
!macroend
|
||||
|
||||
!macro MUI_NEXTPAGE CALL
|
||||
no_first_run:
|
||||
|
||||
IntOp ${CURRENTPAGE} ${CURRENTPAGE} + 1
|
||||
|
||||
Call "${CALL}"
|
||||
|
||||
|
||||
!macroend
|
||||
|
||||
!macro MUI_PREVPAGE CALL
|
||||
|
@ -200,24 +199,24 @@
|
|||
|
||||
;INSTALL OPTIONS
|
||||
|
||||
!macro MUI_INSTALLOPTIONS_INIT
|
||||
|
||||
;Init plugin system (call this when using no plugins before using InstallOptions)
|
||||
|
||||
Call Initialize_____Plugins
|
||||
|
||||
!macroend
|
||||
|
||||
!macro MUI_INSTALLOPTIONS_UNINIT
|
||||
|
||||
;Init plugin system (call this when using no plugins before using InstallOptions)
|
||||
|
||||
Call un.Initialize_____Plugins
|
||||
|
||||
!macroend
|
||||
|
||||
!macro MUI_INSTALLOPTIONS_EXTRACT FILE
|
||||
|
||||
;Init plugin system
|
||||
${IO_INITPLUGINS}
|
||||
!undef IO_INITPLUGINS
|
||||
!define IO_INITPLUGINS ""
|
||||
|
||||
File /oname=$PLUGINSDIR\${FILE} "${FILE}"
|
||||
|
||||
!macroend
|
||||
|
||||
!macro MUI_INSTALLOPTIONS_UNEXTRACT FILE
|
||||
|
||||
;Init plugin system
|
||||
${IO_UNINITPLUGINS}
|
||||
!undef IO_UNINITPLUGINS
|
||||
!define IO_UNINITPLUGINS ""
|
||||
|
||||
File /oname=$PLUGINSDIR\${FILE} "${FILE}"
|
||||
|
||||
!macroend
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue