Bug 1367350 - Add Learn More link for the "Use recommended performance settings" checkbox.
MozReview-Commit-ID: ALEuQlTphKa
--- a/browser/components/preferences/in-content-old/main.js
+++ b/browser/components/preferences/in-content-old/main.js
@@ -59,16 +59,20 @@ var gMainPane = {
let defaultPerformancePref =
document.getElementById("browser.preferences.defaultPerformanceSettings.enabled");
defaultPerformancePref.addEventListener("change", () => {
this.updatePerformanceSettingsBox();
});
this.updatePerformanceSettingsBox();
+ let performanceSettingsLink = document.getElementById("performanceSettingsLearnMore");
+ let performanceSettingsUrl = Services.urlFormatter.formatURLPref("app.support.baseURL") + "performance";
+ performanceSettingsLink.setAttribute("href", performanceSettingsUrl);
+
// set up the "use current page" label-changing listener
this._updateUseCurrentButton();
window.addEventListener("focus", this._updateUseCurrentButton.bind(this));
this.updateBrowserStartupLastSession();
if (AppConstants.platform == "win") {
// Functionality for "Show tabs in taskbar" on Windows 7 and up.
--- a/browser/components/preferences/in-content-old/main.xul
+++ b/browser/components/preferences/in-content-old/main.xul
@@ -317,20 +317,23 @@
preference="browser.taskbar.previews.enable"/>
#endif
</groupbox>
<!-- Performance -->
<groupbox id="performanceGroup" data-category="paneGeneral" hidden="true">
<caption><label>&performance.label;</label></caption>
- <checkbox id="useRecommendedPerformanceSettings"
- label="&useRecommendedPerformanceSettings.label;"
- accesskey="&useRecommendedPerformanceSettings.accesskey;"
- preference="browser.preferences.defaultPerformanceSettings.enabled"/>
+ <hbox align="center">
+ <checkbox id="useRecommendedPerformanceSettings"
+ label="&useRecommendedPerformanceSettings.label;"
+ accesskey="&useRecommendedPerformanceSettings.accesskey;"
+ preference="browser.preferences.defaultPerformanceSettings.enabled"/>
+ <label id="performanceSettingsLearnMore" class="learnMore text-link">&performanceSettingsLearnMore.label;</label>
+ </hbox>
<description class="indent">&useRecommendedPerformanceSettings.description;</description>
<vbox id="performanceSettings" class="indent" hidden="true">
<checkbox id="allowHWAccel"
label="&allowHWAccel.label;"
accesskey="&allowHWAccel.accesskey;"
preference="layers.acceleration.disabled"/>
<hbox align="center">
--- a/browser/locales/en-US/chrome/browser/preferences-old/advanced.dtd
+++ b/browser/locales/en-US/chrome/browser/preferences-old/advanced.dtd
@@ -126,14 +126,16 @@
<!ENTITY performance.label "Performance">
<!ENTITY useRecommendedPerformanceSettings.label
"Use recommended performance settings">
<!ENTITY useRecommendedPerformanceSettings.description
"These settings are tailored to your computer’s hardware and operating system.">
<!ENTITY useRecommendedPerformanceSettings.accesskey
"U">
+<!ENTITY performanceSettingsLearnMore.label
+ "Learn more">
<!ENTITY limitContentProcess.label "Content process limit">
<!ENTITY limitContentProcess.description
"Additional content processes can improve &brandShortName; performance when using multiple tabs, but will also use more memory.">
<!ENTITY limitContentProcess.accesskey "L">
<!ENTITY allowHWAccel.label "Use hardware acceleration when available">
<!ENTITY allowHWAccel.accesskey "r">