Skip to content

Commit

Permalink
Merge pull request #21 from eco/chm-start-menu
Browse files Browse the repository at this point in the history
Add Start Menu shortcut to D2 CHM documentation
  • Loading branch information
WalterBright committed Nov 5, 2013
2 parents c6c70d0 + 190d6d4 commit 7373cf3
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions windows/dinstaller.nsi
Expand Up @@ -381,15 +381,16 @@ Section "Start Menu Shortcuts" StartMenuShortcuts
; install dmd 2 documentation and command prompt
SectionGetFlags ${Dmd2Files} $0
IntOp $0 $0 & ${SF_SELECTED}
IntCmp $0 ${SF_SELECTED} +1 +3
CreateShortCut "$SMPROGRAMS\D\D2 Documentation.lnk" "$INSTDIR\dmd2\html\d\index.html" "" "$INSTDIR\dmd2\html\d\index.html" 0
IntCmp $0 ${SF_SELECTED} +1 +4
CreateShortCut "$SMPROGRAMS\D\D2 HTML Documentation.lnk" "$INSTDIR\dmd2\html\d\index.html"
CreateShortCut "$SMPROGRAMS\D\D2 Documentation.lnk" "$INSTDIR\dmd2\windows\bin\d.chm"
CreateShortCut "$SMPROGRAMS\D\D2 Command Prompt.lnk" '%comspec%' '/k ""$INSTDIR\dmd2vars.bat""' "" "" SW_SHOWNORMAL "" "Open D2 Command Prompt"

; install dmd 1 documentation and command prompt
SectionGetFlags ${Dmd1Files} $0
IntOp $0 $0 & ${SF_SELECTED}
IntCmp $0 ${SF_SELECTED} +1 +3
CreateShortCut "$SMPROGRAMS\D\D1 Documentation.lnk" "$INSTDIR\dmd\html\d\index.html" "" "$INSTDIR\dmd\html\d\index.html" 0
CreateShortCut "$SMPROGRAMS\D\D1 HTML Documentation.lnk" "$INSTDIR\dmd\html\d\index.html"
CreateShortCut "$SMPROGRAMS\D\D1 Command Prompt.lnk" '%comspec%' '/k ""$INSTDIR\dmd1vars.bat""' "" "" SW_SHOWNORMAL "" "Open D1 Command Prompt"

; install dmc command prompt
Expand Down Expand Up @@ -462,7 +463,8 @@ Section "Uninstall"
Delete $INSTDIR\uninstall.exe

; Remove shortcuts
Delete "$SMPROGRAMS\D\D1 Documentation.lnk"
Delete "$SMPROGRAMS\D\D1 HTML Documentation.lnk"
Delete "$SMPROGRAMS\D\D2 HTML Documentation.lnk"
Delete "$SMPROGRAMS\D\D2 Documentation.lnk"
Delete "$SMPROGRAMS\D\$(SHORTCUT_Uninstall).lnk"

Expand Down

0 comments on commit 7373cf3

Please sign in to comment.