Fix
Bug 569998 - No Mozilla Sunbird entry available in Add or Remove Programs in Control Panel. r=NPOTB
--- a/calendar/installer/windows/nsis/installer.nsi
+++ b/calendar/installer/windows/nsis/installer.nsi
@@ -98,16 +98,17 @@ VIAddVersionKey "OriginalFilename" "setu
!insertmacro GetPathFromString
!insertmacro GetParent
!insertmacro ManualCloseAppPrompt
!insertmacro RegCleanMain
!insertmacro RegCleanUninstall
!insertmacro SetBrandNameVars
!insertmacro UnloadUAC
!insertmacro WriteRegStr2
+!insertmacro WriteRegDWORD2
!include shared.nsh
; Helper macros for ui callbacks. Insert these after shared.nsh
!insertmacro CheckCustomCommon
!insertmacro InstallEndCleanupCommon
!insertmacro InstallOnInitCommon
!insertmacro InstallStartCleanupCommon
@@ -302,16 +303,20 @@ Section "-Application" APP_IDX
; We now try to add to HKLM and if that fails to HKCU
; The order that reg keys and values are added is important if you use the
; uninstall log to remove them on uninstall. When using the uninstall log you
; MUST add children first so they will be removed first on uninstall so they
; will be empty when the key is deleted. This allows the uninstaller to
; specify that only empty keys will be deleted.
${SetAppKeys}
+
+ ; Uninstall keys can only exist under HKLM on some versions of windows. Since
+ ; it doesn't cause problems always add them.
+ ${SetUninstallKeys}
; These need special handling on uninstall since they may be overwritten by
; an install into a different location.
StrCpy $0 "Software\Microsoft\Windows\CurrentVersion\App Paths\${FileMainEXE}"
${WriteRegStr2} $TmpVal "$0" "" "$INSTDIR\${FileMainEXE}" 0
${WriteRegStr2} $TmpVal "$0" "Path" "$INSTDIR" 0
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application