WriteRegStr HKCR "Cura AMF model file\shell\open\command" "" '"$INSTDIR\python\pythonw.exe" -c "import os; os.chdir(\"$INSTDIR\"); import Cura.cura; Cura.cura.main()" "%1"'
SectionEnd
-Section /o "Uninstall other Cura versions"
- StrCpy $0 0
- loop:
- EnumRegKey $1 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall" $0
- StrCmp $1 "" done
- IntOp $0 $0 + 1
- StrCmp $1 "Cura_${VERSION}" loop
- ${StrContains} $2 "Cura_" $1
- StrCmp $2 "" loop
-
- ReadRegStr $3 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\$1" "UninstallString"
- ExecWait '$3 /S _?=$INSTDIR'
- done:
-SectionEnd
-
;--------------------------------
; Uninstaller