aboutsummaryrefslogtreecommitdiff
path: root/program_info/win_install.nsi
diff options
context:
space:
mode:
authortimoreo22 <timo.oreo34@gmail.com>2022-05-28 15:36:12 +0200
committerGitHub <noreply@github.com>2022-05-28 15:36:12 +0200
commitf19e27e875b1c312e50e17149dd976decddbce31 (patch)
treec887b6d71e9b7a79105fbf10d1a2d09d386a11e7 /program_info/win_install.nsi
parentc864046cee07d92ceb3a8646a28f21a2715c5098 (diff)
parent997bf9144258c89f4c1e5fb23d7f3218790ac5ea (diff)
downloadPrismLauncher-f19e27e875b1c312e50e17149dd976decddbce31.tar.gz
PrismLauncher-f19e27e875b1c312e50e17149dd976decddbce31.tar.bz2
PrismLauncher-f19e27e875b1c312e50e17149dd976decddbce31.zip
Merge pull request #629 from kthchew/feature/desktop-shortcut
Add desktop shortcut to Windows installer
Diffstat (limited to 'program_info/win_install.nsi')
-rw-r--r--program_info/win_install.nsi12
1 files changed, 10 insertions, 2 deletions
diff --git a/program_info/win_install.nsi b/program_info/win_install.nsi
index 4ca4de1a..cb4c8d1d 100644
--- a/program_info/win_install.nsi
+++ b/program_info/win_install.nsi
@@ -141,12 +141,18 @@ Section "PolyMC"
SectionEnd
-Section "Start Menu Shortcuts" SHORTCUTS
+Section "Start Menu Shortcut" SM_SHORTCUTS
CreateShortcut "$SMPROGRAMS\PolyMC.lnk" "$INSTDIR\polymc.exe" "" "$INSTDIR\polymc.exe" 0
SectionEnd
+Section "Desktop Shortcut" DESKTOP_SHORTCUTS
+
+ CreateShortcut "$DESKTOP\PolyMC.lnk" "$INSTDIR\polymc.exe" "" "$INSTDIR\polymc.exe" 0
+
+SectionEnd
+
;--------------------------------
; Uninstaller
@@ -215,6 +221,7 @@ Section "Uninstall"
RMDir /r $INSTDIR\styles
Delete "$SMPROGRAMS\PolyMC.lnk"
+ Delete "$DESKTOP\PolyMC.lnk"
RMDir "$INSTDIR"
@@ -228,6 +235,7 @@ Function .onInit
${GetParameters} $R0
${GetOptions} $R0 "/NoShortcuts" $R1
${IfNot} ${Errors}
- !insertmacro UnselectSection ${SHORTCUTS}
+ !insertmacro UnselectSection ${SM_SHORTCUTS}
+ !insertmacro UnselectSection ${DESKTOP_SHORTCUTS}
${EndIf}
FunctionEnd