Bug 606482 - Reorganized the Software Installation preferences panel. r=IanN ui-r=Neil
This commit is contained in:
Родитель
df66cfd13e
Коммит
3287067aa0
|
@ -22,6 +22,7 @@
|
|||
*
|
||||
* Contributor(s):
|
||||
* Mark Banner <bugzilla@standard8.plus.com>
|
||||
* Edmund Wong <ewong@pw-wspx.org>
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either of the GNU General Public License Version 2 or later (the "GPL"),
|
||||
|
@ -63,34 +64,27 @@ function Startup()
|
|||
* possibly with a warning if incompatible extensions are installed (see
|
||||
* app.update.mode); false if the user should be asked what he wants to do
|
||||
* when an update is available
|
||||
* app.update.mode
|
||||
* - an integer:
|
||||
* mode: Minor Releases: Major Releases:
|
||||
* 0 download and install, never prompt always prompt
|
||||
*
|
||||
* 1,2 download and install, always prompt
|
||||
* no prompt if no incompatible add-ons
|
||||
*
|
||||
* The app.update.mode preference is converted into a true/false value for
|
||||
* use in determining whether the "Warn me if this will disable extensions
|
||||
* or themes" checkbox is checked. Unlike other toolkit applications we
|
||||
* don't care about supporting legacy mode 2.
|
||||
*
|
||||
* app.update.mode Checkbox State Meaning
|
||||
* 0 Unchecked Warn if the update is major
|
||||
* 1,2 Checked Warn if there are incompatibilities
|
||||
* or the update is major
|
||||
*/
|
||||
function UpdateAddonsItems()
|
||||
{
|
||||
document.getElementById("extensionsUpdatesEnabled").disabled =
|
||||
!document.getElementById("xpinstall.enabled").value ||
|
||||
var addOnsCheck = !document.getElementById("xpinstall.enabled").value;
|
||||
|
||||
document.getElementById("addOnsUpdatesEnabled").disabled =
|
||||
addOnsCheck ||
|
||||
document.getElementById("extensions.update.enabled").locked;
|
||||
|
||||
document.getElementById("extensionsUpdateFrequency").disabled =
|
||||
document.getElementById("addOnsUpdateFrequency").disabled =
|
||||
!document.getElementById("xpinstall.enabled").value ||
|
||||
!document.getElementById("extensions.update.enabled").value ||
|
||||
document.getElementById("extensions.update.interval").locked;
|
||||
|
||||
document.getElementById("allowedSitesButton").disabled =
|
||||
addOnsCheck;
|
||||
|
||||
document.getElementById("addOnsModeAutoEnabled").disabled =
|
||||
addOnsCheck ||
|
||||
!document.getElementById("extensions.update.enabled").value ||
|
||||
document.getElementById("extensions.update.enabled").locked;
|
||||
}
|
||||
|
||||
function UpdateAppItems()
|
||||
|
@ -103,6 +97,11 @@ function UpdateAppItems()
|
|||
document.getElementById("appUpdateFrequency").disabled =
|
||||
!enabledPref.value || !gCanCheckForUpdates ||
|
||||
document.getElementById("app.update.interval").locked;
|
||||
|
||||
document.getElementById("appModeAutoEnabled").disabled =
|
||||
!enabledPref.value || !gCanCheckForUpdates ||
|
||||
document.getElementById("app.update.mode").locked;
|
||||
|
||||
UpdateAutoItems();
|
||||
}
|
||||
|
||||
|
@ -112,21 +111,8 @@ function UpdateAppItems()
|
|||
*/
|
||||
function UpdateAutoItems()
|
||||
{
|
||||
var disabled = !gCanCheckForUpdates||
|
||||
!document.getElementById("app.update.enabled").value ||
|
||||
document.getElementById("app.update.auto").locked;
|
||||
document.getElementById("updateModeLabel").disabled = disabled;
|
||||
document.getElementById("updateMode").disabled = disabled;
|
||||
UpdateModeItems();
|
||||
}
|
||||
|
||||
/**
|
||||
* Enables/disables the "warn if incompatible extensions/themes exist" UI
|
||||
* based on the values and "locked" states of various preferences.
|
||||
*/
|
||||
function UpdateModeItems()
|
||||
{
|
||||
document.getElementById("warnIncompatible").disabled =
|
||||
document.getElementById("appWarnIncompatible").disabled =
|
||||
!gCanCheckForUpdates ||
|
||||
!document.getElementById("app.update.enabled").value ||
|
||||
!document.getElementById("app.update.auto").value ||
|
||||
document.getElementById("app.update.mode").locked;
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
|
||||
Contributor(s):
|
||||
Mark Banner <bugzilla@standard8.plus.com>
|
||||
Edmund Wong <ewong@pw-wspx.org>
|
||||
|
||||
Alternatively, the contents of this file may be used under the terms of
|
||||
either of the GNU General Public License Version 2 or later (the "GPL"),
|
||||
|
@ -63,7 +64,9 @@
|
|||
<preference id="extensions.update.interval"
|
||||
name="extensions.update.interval"
|
||||
type="int"/>
|
||||
|
||||
<preference id="extensions.update.autoUpdateDefault"
|
||||
name="extensions.update.autoUpdateDefault"
|
||||
type="bool"/>
|
||||
<preference id="app.update.enabled"
|
||||
name="app.update.enabled"
|
||||
type="bool"
|
||||
|
@ -71,11 +74,10 @@
|
|||
<preference id="app.update.auto"
|
||||
name="app.update.auto"
|
||||
type="bool"
|
||||
onchange="UpdateAutoItems();"/>
|
||||
onchange="UpdateAppItems();"/>
|
||||
<preference id="app.update.mode"
|
||||
name="app.update.mode"
|
||||
type="int"
|
||||
onchange="UpdateModeItems();"/>
|
||||
type="int"/>
|
||||
<preference id="app.update.interval"
|
||||
name="app.update.interval"
|
||||
type="int"/>
|
||||
|
@ -85,91 +87,92 @@
|
|||
</preferences>
|
||||
|
||||
<groupbox>
|
||||
<caption label="&smartTitle.label;"/>
|
||||
<hbox align="center">
|
||||
<checkbox id="XPInstallEnabled" label="&enableSU.label;" flex="1"
|
||||
accesskey="&enableSU.accesskey;" preference="xpinstall.enabled"/>
|
||||
<button id="allowedSitesButton"
|
||||
label="&viewPermissions.label;"
|
||||
accesskey="&viewPermissions.accesskey;"
|
||||
oncommand="toDataManager('|permissions');"/>
|
||||
</hbox>
|
||||
<caption label="&addOnsTitle.label;"/>
|
||||
<hbox align="center">
|
||||
<checkbox id="XPInstallEnabled"
|
||||
label="&addOnsAllow.label;"
|
||||
flex="1"
|
||||
accesskey="&addOnsAllow.accesskey;"
|
||||
preference="xpinstall.enabled"/>
|
||||
<button id="allowedSitesButton"
|
||||
label="&allowedWebsites.label;"
|
||||
accesskey="&allowedWebsites.accesskey;"
|
||||
oncommand="toDataManager('|permissions');"/>
|
||||
</hbox>
|
||||
<hbox class="indent">
|
||||
<checkbox id="addOnsUpdatesEnabled"
|
||||
label="&autoAddOnsUpdates.label;"
|
||||
accesskey="&autoAddOnsUpdates.accesskey;"
|
||||
preference="extensions.update.enabled"/>
|
||||
<radiogroup id="addOnsUpdateFrequency"
|
||||
orient="horizontal"
|
||||
preference="extensions.update.interval">
|
||||
<radio id="addOnsFreqDaily"
|
||||
label="&daily.label;"
|
||||
accesskey="&addOnsDaily.accesskey;"
|
||||
value="86400"/>
|
||||
<radio id="addOnsFreqWeekly"
|
||||
label="&weekly.label;"
|
||||
accesskey="&addOnsWeekly.accesskey;"
|
||||
value="604800"/>
|
||||
</radiogroup>
|
||||
</hbox>
|
||||
<hbox class="indent">
|
||||
<checkbox id="addOnsModeAutoEnabled"
|
||||
class="indent"
|
||||
label="&addOnsModeAutomatic.label;"
|
||||
flex="1"
|
||||
accesskey="&addOnsModeAutomatic.accesskey;"
|
||||
preference="extensions.update.autoUpdateDefault"/>
|
||||
</hbox>
|
||||
<hbox pack="end">
|
||||
<button id="startAddonManager"
|
||||
oncommand="toEM('addons://list/extensions');"
|
||||
label="&addonManagerButton.label;"
|
||||
accesskey="&addonManagerButton.accesskey;"/>
|
||||
</hbox>
|
||||
</groupbox>
|
||||
|
||||
<groupbox>
|
||||
<caption label="&verifyUpdates.caption;"/>
|
||||
<description>&autoUpdates.label;</description>
|
||||
<grid>
|
||||
<columns>
|
||||
<column/>
|
||||
<column/>
|
||||
</columns>
|
||||
|
||||
<rows>
|
||||
<row>
|
||||
<checkbox id="appUpdatesEnabled" label="&appUpdates.label;"
|
||||
accesskey="&appUpdates.accesskey;"
|
||||
preference="app.update.enabled"/>
|
||||
<radiogroup id="appUpdateFrequency" orient="horizontal"
|
||||
preference="app.update.interval">
|
||||
<radio id="appFreqDaily" label="&daily.label;"
|
||||
accesskey="&appDaily.accesskey;" value="86400"/>
|
||||
<radio id="appFreqWeekly" label="&weekly.label;"
|
||||
accesskey="&appWeekly.accesskey;" value="604800"/>
|
||||
</radiogroup>
|
||||
</row>
|
||||
<row>
|
||||
<checkbox id="extensionsUpdatesEnabled"
|
||||
label="&extensionsUpdates.label;"
|
||||
accesskey="&extensionsUpdates.accesskey;"
|
||||
preference="extensions.update.enabled"/>
|
||||
<radiogroup id="extensionsUpdateFrequency" orient="horizontal"
|
||||
preference="extensions.update.interval">
|
||||
<radio id="extensionsFreqDaily" label="&daily.label;"
|
||||
accesskey="&extensionsDaily.accesskey;" value="86400"/>
|
||||
<radio id="extensionsFreqWeekly" label="&weekly.label;"
|
||||
accesskey="&extensionsWeekly.accesskey;" value="604800"/>
|
||||
</radiogroup>
|
||||
</row>
|
||||
</rows>
|
||||
</grid>
|
||||
<vbox align="end">
|
||||
<button id="startAddonManager"
|
||||
oncommand="toEM('addons://list/extensions');"
|
||||
label="&addonManagerButton.label;"
|
||||
accesskey="&addonManagerButton.accesskey;"/>
|
||||
</vbox>
|
||||
</groupbox>
|
||||
|
||||
<groupbox>
|
||||
<caption id="updateModeLabel"
|
||||
label="&whenUpdatesFound.label;"
|
||||
control="updateMode"/>
|
||||
<radiogroup id="updateMode"
|
||||
preference="app.update.auto">
|
||||
<radio id="updateModeAsk"
|
||||
label="&askMe.label;"
|
||||
accesskey="&askMe.accesskey;"
|
||||
value="false"/>
|
||||
<radio id="updateModeAutomatic"
|
||||
label="&modeAutomatic.label;"
|
||||
accesskey="&modeAutomatic.accesskey;"
|
||||
value="true"/>
|
||||
<checkbox id="warnIncompatible"
|
||||
class="indent"
|
||||
label="&modeAutoAddonWarn.label;"
|
||||
accesskey="&modeAutoAddonWarn.accesskey;"
|
||||
preference="app.update.mode"
|
||||
onsynctopreference="return this.checked ? 1 : 0;"/>
|
||||
</radiogroup>
|
||||
|
||||
<hbox pack="end">
|
||||
<button id="showUpdateHistory"
|
||||
label="&updateHistory.label;"
|
||||
accesskey="&updateHistory.accesskey;"
|
||||
preference="app.update.disable_button.showUpdateHistory"
|
||||
oncommand="ShowUpdateHistory();"/>
|
||||
</hbox>
|
||||
<caption label="&appUpdates.caption;"/>
|
||||
<hbox>
|
||||
<checkbox id="appUpdatesEnabled"
|
||||
label="&autoAppUpdates.label;"
|
||||
accesskey="&autoAppUpdates.accesskey;"
|
||||
preference="app.update.enabled"/>
|
||||
<radiogroup id="appUpdateFrequency"
|
||||
orient="horizontal"
|
||||
preference="app.update.interval">
|
||||
<radio id="appFreqDaily"
|
||||
label="&daily.label;"
|
||||
accesskey="&appDaily.accesskey;"
|
||||
value="86400"/>
|
||||
<radio id="appFreqWeekly"
|
||||
label="&weekly.label;"
|
||||
accesskey="&appWeekly.accesskey;"
|
||||
value="604800"/>
|
||||
</radiogroup>
|
||||
</hbox>
|
||||
<vbox class="indent">
|
||||
<checkbox id="appModeAutoEnabled"
|
||||
label="&appModeAutomatic.label;"
|
||||
flex="1"
|
||||
accesskey="&appModeAutomatic.accesskey;"
|
||||
preference="app.update.auto"/>
|
||||
<checkbox id="appWarnIncompatible"
|
||||
class="indent"
|
||||
label="&appModeAutoAddonWarn.label;"
|
||||
accesskey="&appModeAutoAddonWarn.accesskey;"
|
||||
preference="app.update.mode"
|
||||
onsynctopreference="return this.checked ? 1 : 0;"/>
|
||||
</vbox>
|
||||
<hbox pack="end">
|
||||
<button id="showUpdateHistory"
|
||||
label="&updateHistory.label;"
|
||||
accesskey="&updateHistory.accesskey;"
|
||||
preference="app.update.disable_button.showUpdateHistory"
|
||||
oncommand="ShowUpdateHistory();"/>
|
||||
</hbox>
|
||||
</groupbox>
|
||||
</prefpane>
|
||||
</overlay>
|
||||
|
|
|
@ -1,32 +1,29 @@
|
|||
<!--LOCALIZATION NOTE : FILE UI for Software Updates prefs -->
|
||||
<!ENTITY pref.smartUpdate.title "Software Installation">
|
||||
<!ENTITY smartTitle.label "Manage Software Installations and Updates">
|
||||
<!ENTITY enableSU.label "Allow websites to install extensions and updates">
|
||||
<!ENTITY enableSU.accesskey "x">
|
||||
<!ENTITY viewPermissions.label "Manage Permissions">
|
||||
<!ENTITY viewPermissions.accesskey "P">
|
||||
|
||||
<!ENTITY verifyUpdates.caption "Updates">
|
||||
<!ENTITY autoUpdates.label "Automatically check for updates to:">
|
||||
<!ENTITY appUpdates.label "&brandShortName;">
|
||||
<!ENTITY appUpdates.accesskey "S">
|
||||
<!ENTITY addOnsTitle.label "Add-ons">
|
||||
<!ENTITY addOnsAllow.label "Allow websites to install add-ons and updates">
|
||||
<!ENTITY addOnsAllow.accesskey "b">
|
||||
<!ENTITY allowedWebsites.label "Allowed Websites">
|
||||
<!ENTITY allowedWebsites.accesskey "W">
|
||||
<!ENTITY autoAddOnsUpdates.label "Automatically check for updates">
|
||||
<!ENTITY autoAddOnsUpdates.accesskey "o">
|
||||
<!ENTITY daily.label "daily">
|
||||
<!ENTITY appDaily.accesskey "d">
|
||||
<!ENTITY addOnsDaily.accesskey "d">
|
||||
<!ENTITY weekly.label "weekly">
|
||||
<!ENTITY appWeekly.accesskey "w">
|
||||
<!ENTITY extensionsUpdates.label "Installed Add-ons">
|
||||
<!ENTITY extensionsUpdates.accesskey "o">
|
||||
<!ENTITY extensionsDaily.accesskey "a">
|
||||
<!ENTITY extensionsWeekly.accesskey "k">
|
||||
<!ENTITY addOnsWeekly.accesskey "k">
|
||||
<!ENTITY addOnsModeAutomatic.label "Automatically download and install the updates">
|
||||
<!ENTITY addOnsModeAutomatic.accesskey "c">
|
||||
<!ENTITY addonManagerButton.label "Add-on Manager">
|
||||
<!ENTITY addonManagerButton.accesskey "M">
|
||||
|
||||
<!ENTITY whenUpdatesFound.label "When updates to &brandShortName; are found">
|
||||
<!ENTITY askMe.label "Ask me what I want to do">
|
||||
<!ENTITY askMe.accesskey "n">
|
||||
<!ENTITY modeAutomatic.label "Automatically download and install the update">
|
||||
<!ENTITY modeAutomatic.accesskey "c">
|
||||
<!ENTITY modeAutoAddonWarn.label "Warn me if this will disable any of my add-ons">
|
||||
<!ENTITY modeAutoAddonWarn.accesskey "b">
|
||||
<!ENTITY appUpdates.caption "&brandShortName;">
|
||||
<!ENTITY autoAppUpdates.label "Automatically check for updates">
|
||||
<!ENTITY autoAppUpdates.accesskey "t">
|
||||
<!ENTITY appDaily.accesskey "a">
|
||||
<!ENTITY appWeekly.accesskey "e">
|
||||
<!ENTITY appModeAutomatic.label "Automatically download and install the update">
|
||||
<!ENTITY appModeAutomatic.accesskey "u">
|
||||
<!ENTITY appModeAutoAddonWarn.label "Warn me if this will disable any of my add-ons">
|
||||
<!ENTITY appModeAutoAddonWarn.accesskey "n">
|
||||
<!ENTITY updateHistory.label "Show Update History">
|
||||
<!ENTITY updateHistory.accesskey "u">
|
||||
<!ENTITY updateHistory.accesskey "S">
|
||||
|
|
Загрузка…
Ссылка в новой задаче