merge m-c to fx-team

This commit is contained in:
Tim Taubert
2012-03-28 00:33:42 +02:00
26 changed files with 764 additions and 594 deletions

View File

@@ -103,7 +103,7 @@ VIAddVersionKey "OriginalFilename" "setup.exe"
; Must be inserted before other macros that use logging
!insertmacro _LoggingCommon
!insertmacro AddDDEHandlerValues
!insertmacro AddDisabledDDEHandlerValues
!insertmacro ChangeMUIHeaderImage
!insertmacro CheckForFilesInUse
!insertmacro CleanUpdatesDir
@@ -352,17 +352,15 @@ Section "-Application" APP_IDX
${SetUninstallKeys}
; On install always add the FirefoxHTML and FirefoxURL keys.
; An empty string is used for the 5th param because FirefoxHTML and FirefoxURL
; are not protocol handlers.
; An empty string is used for the 5th param because FirefoxHTML is not a
; protocol handler.
${GetLongPath} "$INSTDIR\${FileMainEXE}" $8
StrCpy $2 "$\"$8$\" -requestPending -osint -url $\"%1$\""
StrCpy $3 "$\"%1$\",,0,0,,,,"
StrCpy $2 "$\"$8$\" -osint -url $\"%1$\""
${AddDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" "${AppRegName} Document" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDDEHandlerValues} "FirefoxURL" "$2" "$8,1" "${AppRegName} URL" "true" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" \
"${AppRegName} Document" ""
${AddDisabledDDEHandlerValues} "FirefoxURL" "$2" "$8,1" "${AppRegName} URL" \
"true"
; The following keys should only be set if we can write to HKLM
${If} $TmpVal == "HKLM"

View File

@@ -79,7 +79,7 @@
${GetLongPath} "$0" $0
${EndIf}
${If} "$0" == "$INSTDIR"
${SetStartMenuInternet}
${SetStartMenuInternet} ; Does not use SHCTX
${EndIf}
ReadRegStr $0 HKLM "Software\mozilla.org\Mozilla" "CurrentVersion"
@@ -156,12 +156,12 @@
!define PostUpdate "!insertmacro PostUpdate"
!macro SetAsDefaultAppGlobal
${RemoveDeprecatedKeys}
${RemoveDeprecatedKeys} ; Does not use SHCTX
SetShellVarContext all ; Set SHCTX to all users (e.g. HKLM)
${SetHandlers}
${SetStartMenuInternet}
${FixShellIconHandler}
${SetHandlers} ; Uses SHCTX
${SetStartMenuInternet} ; Does not use SHCTX
${FixShellIconHandler} ; Does not use SHCTX
${ShowShortcuts}
${StrFilter} "${FileMainEXE}" "+" "" "" $R9
WriteRegStr HKLM "Software\Clients\StartMenuInternet" "" "$R9"
@@ -306,7 +306,7 @@
${GetLongPath} "$INSTDIR\${FileMainEXE}" $8
StrCpy $0 "SOFTWARE\Classes"
StrCpy $2 "$\"$8$\" -requestPending -osint -url $\"%1$\""
StrCpy $2 "$\"$8$\" -osint -url $\"%1$\""
; Associate the file handlers with FirefoxHTML
ReadRegStr $6 SHCTX "$0\.htm" ""
@@ -340,25 +340,20 @@
WriteRegStr SHCTX "$0\.webm" "" "FirefoxHTML"
${EndIf}
StrCpy $3 "$\"%1$\",,0,0,,,,"
; An empty string is used for the 5th param because FirefoxHTML is not a
; protocol handler
${AddDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" "${AppRegName} HTML Document" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" \
"${AppRegName} HTML Document" ""
${AddDDEHandlerValues} "FirefoxURL" "$2" "$8,1" "${AppRegName} URL" "true" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "FirefoxURL" "$2" "$8,1" "${AppRegName} URL" \
"true"
; An empty string is used for the 4th & 5th params because the following
; protocol handlers already have a display name and the additional keys
; required for a protocol handler.
${AddDDEHandlerValues} "ftp" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDDEHandlerValues} "http" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDDEHandlerValues} "https" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "ftp" "$2" "$8,1" "" ""
${AddDisabledDDEHandlerValues} "http" "$2" "$8,1" "" ""
${AddDisabledDDEHandlerValues} "https" "$2" "$8,1" "" ""
!macroend
!define SetHandlers "!insertmacro SetHandlers"
@@ -567,8 +562,7 @@
!macro UpdateProtocolHandlers
; Store the command to open the app with an url in a register for easy access.
${GetLongPath} "$INSTDIR\${FileMainEXE}" $8
StrCpy $2 "$\"$8$\" -requestPending -osint -url $\"%1$\""
StrCpy $3 "$\"%1$\",,0,0,,,,"
StrCpy $2 "$\"$8$\" -osint -url $\"%1$\""
; Only set the file and protocol handlers if the existing one under HKCR is
; for this install location.
@@ -577,32 +571,32 @@
${If} "$R9" == "true"
; An empty string is used for the 5th param because FirefoxHTML is not a
; protocol handler.
${AddDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" "${AppRegName} HTML Document" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "FirefoxHTML" "$2" "$8,1" \
"${AppRegName} HTML Document" ""
${EndIf}
${IsHandlerForInstallDir} "FirefoxURL" $R9
${If} "$R9" == "true"
${AddDDEHandlerValues} "FirefoxURL" "$2" "$8,1" "${AppRegName} URL" "true" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "FirefoxURL" "$2" "$8,1" \
"${AppRegName} URL" "true"
${EndIf}
; An empty string is used for the 4th & 5th params because the following
; protocol handlers already have a display name and the additional keys
; required for a protocol handler.
${IsHandlerForInstallDir} "ftp" $R9
${If} "$R9" == "true"
${AddDDEHandlerValues} "ftp" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "ftp" "$2" "$8,1" "" ""
${EndIf}
${IsHandlerForInstallDir} "http" $R9
${If} "$R9" == "true"
${AddDDEHandlerValues} "http" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "http" "$2" "$8,1" "" ""
${EndIf}
${IsHandlerForInstallDir} "https" $R9
${If} "$R9" == "true"
${AddDDEHandlerValues} "https" "$2" "$8,1" "" "" \
"${DDEApplication}" "$3" "WWW_OpenURL"
${AddDisabledDDEHandlerValues} "https" "$2" "$8,1" "" ""
${EndIf}
!macroend
!define UpdateProtocolHandlers "!insertmacro UpdateProtocolHandlers"
@@ -1164,11 +1158,13 @@ Function SetAsDefaultAppUser
; b) is not a member of the administrators group and chooses to elevate
${ElevateUAC}
${SetStartMenuInternet}
${SetStartMenuInternet} ; Does not use SHCTX
SetShellVarContext all ; Set SHCTX to all users (e.g. HKLM)
${FixShellIconHandler}
${RemoveDeprecatedKeys}
${FixClassKeys} ; Does not use SHCTX
${FixShellIconHandler} ; Does not use SHCTX
${RemoveDeprecatedKeys} ; Does not use SHCTX
ClearErrors
${GetParameters} $0

View File

@@ -92,7 +92,7 @@ Var MaintCertKey
VIAddVersionKey "FileDescription" "${BrandShortName} Helper"
VIAddVersionKey "OriginalFilename" "helper.exe"
!insertmacro AddDDEHandlerValues
!insertmacro AddDisabledDDEHandlerValues
!insertmacro CleanVirtualStore
!insertmacro ElevateUAC
!insertmacro GetLongPath