[Launch]
ProgramExecutable=RDI\R-DriveImage.exe
SinglePortableAppInstance=True
WaitForEXE1=cdrecord.exe
WaitForEXE2=hhe.exe
WaitForEXE3=r-driveimagecl.exe
WaitForEXE4=RdrVmpUninstall32.exe
WaitForEXE5=RdrVmpUninstall64.exe
WaitForEXE6=rhelper.exe
WaitForEXE7=rvss64.exe

[Activate]                      
Registry=true

[RegistryKeys]
{f9d359bc-003b-4ea3-8142-6808f1530333}=HKLM\SOFTWARE\Classes\CLSID\{f9d359bc-003b-4ea3-8142-6808f1530333}
rdi=HKLM\SOFTWARE\Classes\.rdi
rdr=HKLM\SOFTWARE\Classes\.rdr
R-Drive Image.CommandFile=HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile
R-Drive Image.File=HKLM\SOFTWARE\Classes\R-Drive Image.File
R-DriveImage=HKCU\Software\R-TT\R-DriveImage
r-driveimagecl.exe=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\r-driveimagecl.exe

[RegistryValueWrite]
HKLM\SOFTWARE\Classes\CLSID\{f9d359bc-003b-4ea3-8142-6808f1530333}\InprocServer32\LastGoodState=REG_BINARY:009f97c54ded9fd9472d7e84bf0ba4f050cd0c9f7d55c76acd5a6f30569f7429a949d57f691c8580e6a0a637a0c8c1af8d6243d45b819a8d9b18e32ac265c9edf2e8264fbc5a2ac7040b45bdf9659d43d2798290bc84be7491df1e03279e6efe13f64d35303e91a01a98fbc59d03d59a6a8c9e163dc7076bf481c1a2cb4f26c6db30997de9da6b9518661f
HKLM\SOFTWARE\Classes\.rdi\=REG_SZ:R-Drive Image.CommandFile
HKLM\SOFTWARE\Classes\.rdr\=REG_SZ:R-Drive Image.File
HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile\=REG_SZ:Command file of R-Drive Image
HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile\DefaultIcon\=REG_SZ:%PAL:AppDir%\RDI\R-DriveImage.exe,6
HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile\shell\
HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile\shell\open\=REG_SZ:Run
HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile\shell\open\command\=REG_SZ:"\"r-driveimagecl.exe\" cmd=\"%1\""
HKLM\SOFTWARE\Classes\R-Drive Image.File\=REG_SZ:Image file of R-Drive Image
HKLM\SOFTWARE\Classes\R-Drive Image.File\DefaultIcon\=REG_SZ:%PAL:AppDir%\RDI\R-DriveImage.exe,4
HKLM\SOFTWARE\Classes\R-Drive Image.File\shell\
HKLM\SOFTWARE\Classes\R-Drive Image.File\shell\mount\=REG_SZ:
HKLM\SOFTWARE\Classes\R-Drive Image.File\shell\mount\command\=REG_SZ:%PAL:AppDir%\RDI\R-DriveImage.exe\" mount -a=\"%1\"
HKLM\SOFTWARE\Classes\R-Drive Image.File\shell\open\=REG_SZ:
HKLM\SOFTWARE\Classes\R-Drive Image.File\shell\open\command\=REG_SZ:%PAL:AppDir%\RDI\R-DriveImage.exe\" restorechoose -a=\"%1\"
HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\r-driveimagecl.exe\=REG_SZ:%PAL:AppDir%\RDI\r-driveimagecl.exe
HKCU\Software\R-TT\R-DriveImage\uname=REG_SZ:R-Drive Image
HKCU\Software\R-TT\R-DriveImage\ucompany=REG_SZ:R-Tools Technology Inc.
HKCU\Software\R-TT\R-DriveImage\settings\DontShowStartPage=REG_DWORD:1

[RegistryCleanupForce]
1=HKLM\SOFTWARE\Classes\CLSID\{f9d359bc-003b-4ea3-8142-6808f1530333}
2=HKLM\SOFTWARE\Classes\.rdi
3=HKLM\SOFTWARE\Classes\.rdr
4=HKLM\SOFTWARE\Classes\R-Drive Image.CommandFile
5=HKLM\SOFTWARE\Classes\R-Drive Image.File
6=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\r-driveimagecl.exe
7=HKLM\SOFTWARE\R-TT
8=HKLM\SOFTWARE\WOW6432Node\R-TT
9=HKCU\Software\R-TT

[FileWrite1]
Type=Replace
File=%PAL:DataDir%\settings\R-DriveImagePortableSettings.ini
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:DoubleBackslash%\\
Replace=%PAL:Drive%%PAL:PackagePartialDir:DoubleBackslash%\\

[FileWrite2]
Type=Replace
File=%PAL:DataDir%\settings\R-DriveImagePortableSettings.ini
Find=%PAL:LastPortableAppsBaseDir:DoubleBackslash%\\
Replace=%PAL:PortableAppsBaseDir:DoubleBackslash%\\

[FileWrite3]
Type=Replace
File=%PAL:DataDir%\settings\R-DriveImagePortableSettings.ini
Find=%PAL:LastDrive%\\
Replace=%PAL:Drive%\\