!macro CustomCodePreInstall
	${If} ${FileExists} "$INSTDIR\Data\PortableApps.comLauncherRuntimeData-PixeloramaPortable.ini"
		Rename "$INSTDIR\App\Pixelorama\pixelorama_data" "$INSTDIR\Data\pixelorama_data"
		Delete "$INSTDIR\Data\PortableApps.comLauncherRuntimeData-PixeloramaPortable.ini"
	${EndIf}
!macroend

!macro CustomCodePostInstall
	${If} ${FileExists} "$INSTDIR\Data\pixelorama_data\*.*"
		CopyFiles /SILENT "$INSTDIR\App\DefaultData\pixelorama_data\*.*" "$INSTDIR\Data\pixelorama_data"
		WriteINIStr "$INSTDIR\Data\settings\PixeloramaPortableSettings.ini" "PixeloramaPortableSettings" "DataVersion" $1
	${EndIf}
!macroend
