pcsx2/nsis/SectionUninstaller.nsh
ramapcsx2 fe72821eaa Made the uninstaller nicer / removed some unused stuff.
The uninstaller now removes all PCSX2 paths info, so that a reinstall works as expected.
It also offers to remove plugin configuration files and user created files separately.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4508 96395faa-99c1-11dd-bbfe-3dabce05a288
2011-03-29 17:55:48 +00:00

45 lines
1.4 KiB
NSIS

; =======================================================================
; Un.Installer Sections
; =======================================================================
; (currently web and main installers share the same uninstaller behavior. This
; may change in the future, though I doubt it.)
; -----------------------------------------------------------------------
Section "Un.Program and Plugins ${APP_NAME}"
SetShellVarContext all
!insertmacro UNINSTALL.LOG_UNINSTALL "$INSTDIR"
; Remove uninstaller info reg key ( Wow6432Node on 64bit Windows! )
DeleteRegKey HKLM "${INSTDIR_REG_KEY}"
Call un.removeShorties
!insertmacro UNINSTALL.LOG_UNINSTALL "$INSTDIR\Langs"
!insertmacro UNINSTALL.LOG_UNINSTALL "$INSTDIR\Plugins"
!insertmacro UNINSTALL.LOG_UNINSTALL "$INSTDIR\Docs"
!insertmacro UNINSTALL.LOG_UNINSTALL "$INSTDIR\Cheats"
; Remove files and registry key that store PCSX2 paths configurations
SetShellVarContext current
Delete $DOCUMENTS\PCSX2\inis\PCSX2_ui.ini
DeleteRegKey HKCU Software\PCSX2
SectionEnd
; /o for optional and unticked by default
Section /o "Un.Program and Plugin configuration files"
SetShellVarContext current
RMDir /r "$DOCUMENTS\PCSX2\inis\"
SectionEnd
; /o for optional and unticked by default
Section /o "Un.User files (Memory Cards, Savestates, BIOS, etc)"
SetShellVarContext current
RMDir /r "$DOCUMENTS\PCSX2\"
SectionEnd