Bug 1431027 - Update disk space warning to reflect the latest preferences. r=nhnt11
This changes the disk space notification to show the correct preferences path
and to use the correct openPreferences arguments.
MozReview-Commit-ID: BuKAUvDjp9T
--- a/browser/base/content/browser.js
+++ b/browser/base/content/browser.js
@@ -532,33 +532,33 @@ const gStoragePressureObserver = {
buttons.push({
label: prefStrBundle.getString("spaceAlert.under5GB.okButton.label"),
accessKey: prefStrBundle.getString("spaceAlert.under5GB.okButton.accesskey"),
callback() {}
});
} else {
// The firefox-used space >= 5GB, then guide users to about:preferences
// to clear some data stored on firefox by websites.
- let descriptionStringID = "spaceAlert.over5GB.message";
+ let descriptionStringID = "spaceAlert.over5GB.message1";
let prefButtonLabelStringID = "spaceAlert.over5GB.prefButton.label";
let prefButtonAccesskeyStringID = "spaceAlert.over5GB.prefButton.accesskey";
if (AppConstants.platform == "win") {
- descriptionStringID = "spaceAlert.over5GB.messageWin";
+ descriptionStringID = "spaceAlert.over5GB.messageWin1";
prefButtonLabelStringID = "spaceAlert.over5GB.prefButtonWin.label";
prefButtonAccesskeyStringID = "spaceAlert.over5GB.prefButtonWin.accesskey";
}
msg = prefStrBundle.getFormattedString(descriptionStringID, [brandShortName]);
buttons.push({
label: prefStrBundle.getString(prefButtonLabelStringID),
accessKey: prefStrBundle.getString(prefButtonAccesskeyStringID),
callback(notificationBar, button) {
// The advanced subpanes are only supported in the old organization, which will
// be removed by bug 1349689.
let win = gBrowser.ownerGlobal;
- win.openPreferences("panePrivacy", { origin: "storagePressure" });
+ win.openPreferences("privacy-sitedata", { origin: "storagePressure" });
}
});
}
notificationBox.appendNotification(
msg, NOTIFICATION_VALUE, null, notificationBox.PRIORITY_WARNING_HIGH, buttons, null);
}
};
--- a/browser/components/preferences/in-content/privacy.xul
+++ b/browser/components/preferences/in-content/privacy.xul
@@ -165,17 +165,17 @@
</vbox>
</hbox>
</groupbox>
<!-- Site Data -->
<groupbox id="siteDataGroup" hidden="true" data-category="panePrivacy" data-hidden-from-search="true">
<caption><label>&siteData1.label;</label></caption>
- <hbox align="baseline">
+ <hbox data-subcategory="sitedata" align="baseline">
<vbox flex="1">
<radiogroup id="acceptCookies"
preference="network.cookie.cookieBehavior"
onsyncfrompreference="return gPrivacyPane.readAcceptCookies();"
onsynctopreference="return gPrivacyPane.writeAcceptCookies();">
<description flex="1">
<label id="totalSiteDataSize" class="tail-with-learn-more"></label>
<label id="siteDataLearnMoreLink" class="learnMore text-link">&siteDataLearnMoreLink.label;</label>
--- a/browser/locales/en-US/chrome/browser/preferences/preferences.properties
+++ b/browser/locales/en-US/chrome/browser/preferences/preferences.properties
@@ -189,22 +189,22 @@ removeAllSiteDataShown.label=Remove All
removeAllSiteDataShown.accesskey=e
spaceAlert.learnMoreButton.label=Learn More
spaceAlert.learnMoreButton.accesskey=L
spaceAlert.over5GB.prefButton.label=Open Preferences
spaceAlert.over5GB.prefButton.accesskey=O
# LOCALIZATION NOTE (spaceAlert.over5GB.prefButtonWin.label): On Windows Preferences is called Options
spaceAlert.over5GB.prefButtonWin.label=Open Options
spaceAlert.over5GB.prefButtonWin.accesskey=O
-# LOCALIZATION NOTE (spaceAlert.over5GB.message): %S = brandShortName
-spaceAlert.over5GB.message=%S is running out of disk space. Website contents may not display properly. You can clear stored site data in Preferences > Advanced > Site Data.
-# LOCALIZATION NOTE (spaceAlert.over5GB.messageWin):
+# LOCALIZATION NOTE (spaceAlert.over5GB.message1): %S = brandShortName
+spaceAlert.over5GB.message1=%S is running out of disk space. Website contents may not display properly. You can clear stored data in Preferences > Privacy & Security > Cookies and Site Data.
+# LOCALIZATION NOTE (spaceAlert.over5GB.messageWin1):
# - On Windows Preferences is called Options
# - %S = brandShortName
-spaceAlert.over5GB.messageWin=%S is running out of disk space. Website contents may not display properly. You can clear stored site data in Options > Advanced > Site Data.
+spaceAlert.over5GB.messageWin1=%S is running out of disk space. Website contents may not display properly. You can clear stored data in Options > Privacy & Security > Cookies and Site Data.
spaceAlert.under5GB.okButton.label=OK, Got it
spaceAlert.under5GB.okButton.accesskey=K
# LOCALIZATION NOTE (spaceAlert.under5GB.message): %S = brandShortName
spaceAlert.under5GB.message=%S is running out of disk space. Website contents may not display properly. Visit “Learn More” to optimize your disk usage for better browsing experience.
disableContainersAlertTitle=Close All Container Tabs?
# LOCALIZATION NOTE (disableContainersMsg): Semi-colon list of plural forms.