зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1592968 Followup - Write the pinned to taskbar flag in a place the unelevated helper can write to. r=agashlin
The previous patch didn't work because the helper running as the unelevated user is the only one that can read the pref out of its user registry hive, which is where Firefox has to write it, but then since it's limited it can't write to either the shortcut log or to HKLM. So everything has to happen in HKCU so that the unelevated helper can both read and write where it needs to read and write to. Differential Revision: https://phabricator.services.mozilla.com/D53113 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
58f75fdd03
Коммит
d69dc58f66
|
@ -1095,16 +1095,6 @@
|
|||
; installation time, then we don't get the opportunity to run this code at
|
||||
; that time.
|
||||
!macro MigrateTaskBarShortcut
|
||||
; Find out if this is an ESR build or not, because it affects what we've
|
||||
; named some of our application registry keys.
|
||||
ClearErrors
|
||||
${WordFind} "${UpdateChannel}" "esr" "E#" $3
|
||||
${If} ${Errors}
|
||||
StrCpy $3 ""
|
||||
${Else}
|
||||
StrCpy $3 " ESR"
|
||||
${EndIf}
|
||||
|
||||
${GetShortcutsLogPath} $0
|
||||
${If} ${FileExists} "$0"
|
||||
ClearErrors
|
||||
|
@ -1112,8 +1102,8 @@
|
|||
${If} ${Errors}
|
||||
ClearErrors
|
||||
WriteIniStr "$0" "TASKBAR" "Migrated" "true"
|
||||
WriteRegDWORD SHCTX \
|
||||
"Software\Mozilla\${BrandFullNameInternal}\${AppVersion}$3 (${ARCH} ${AB_CD})\Main" \
|
||||
WriteRegDWORD HKCU \
|
||||
"Software\Mozilla\${AppName}\Installer\$AppUserModelID" \
|
||||
"WasPinnedToTaskbar" 1
|
||||
${If} ${AtLeastWin7}
|
||||
; If we didn't run the stub installer, AddTaskbarSC will be empty.
|
||||
|
@ -1147,12 +1137,12 @@
|
|||
; again, but also record that we've done so by writing a particular
|
||||
; registry value, so that we don't continue to do this repeatedly.
|
||||
ClearErrors
|
||||
ReadRegDWORD $2 SHCTX \
|
||||
"Software\Mozilla\${BrandFullNameInternal}\${AppVersion}$3 (${ARCH} ${AB_CD})\Main" \
|
||||
ReadRegDWORD $2 HKCU \
|
||||
"Software\Mozilla\${AppName}\Installer\$AppUserModelID" \
|
||||
"WasPinnedToTaskbar"
|
||||
${If} ${Errors}
|
||||
WriteRegDWORD SHCTX \
|
||||
"Software\Mozilla\${BrandFullNameInternal}\${AppVersion}$3 (${ARCH} ${AB_CD})\Main" \
|
||||
WriteRegDWORD HKCU \
|
||||
"Software\Mozilla\${AppName}\Installer\$AppUserModelID" \
|
||||
"WasPinnedToTaskbar" 1
|
||||
${If} $AddTaskbarSC != "0"
|
||||
${PinToTaskBar}
|
||||
|
|
Загрузка…
Ссылка в новой задаче