Bug 1336869 - modify the access key for 'unmute tab'. draft
authorAlastor Wu <alwu@mozilla.com>
Tue, 07 Feb 2017 14:49:36 +0800
changeset 479764 d917b6ed67c695e2bc8ec37f82b0007b711e0fbc
parent 479651 af8a2573d0f1e9cc6f2ba0ab67d7a702a197f177
child 544770 598f1f23aa5e3f71e20a13b15d462b66b23a1a3e
push id44347
push useralwu@mozilla.com
push dateTue, 07 Feb 2017 06:47:58 +0000
bugs1336869, 1336309
milestone54.0a1
Bug 1336869 - modify the access key for 'unmute tab'. Fork from bug1336309 comment2, unmuteTab used "M" as access key, but we should change to "m" because the character is lowercase in the label. MozReview-Commit-ID: 3q2luFLbFlQ
browser/base/content/test/general/browser_audioTabIcon.js
browser/locales/en-US/chrome/browser/browser.properties
--- a/browser/base/content/test/general/browser_audioTabIcon.js
+++ b/browser/base/content/test/general/browser_audioTabIcon.js
@@ -153,19 +153,20 @@ function* test_muting_using_menu(tab, ex
   // Show the popup menu
   let contextMenu = document.getElementById("tabContextMenu");
   let popupShownPromise = BrowserTestUtils.waitForEvent(contextMenu, "popupshown");
   EventUtils.synthesizeMouseAtCenter(tab, {type: "contextmenu", button: 2});
   yield popupShownPromise;
 
   // Check the menu
   let expectedLabel = expectMuted ? "Unmute Tab" : "Mute Tab";
+  let expectedAccessKey = expectMuted ? "m" : "M";
   let toggleMute = document.getElementById("context_toggleMuteTab");
   is(toggleMute.label, expectedLabel, "Correct label expected");
-  is(toggleMute.accessKey, "M", "Correct accessKey expected");
+  is(toggleMute.accessKey, expectedAccessKey, "Correct accessKey expected");
 
   is(toggleMute.hasAttribute("muted"), expectMuted, "Should have the correct state for the muted attribute");
   ok(!toggleMute.hasAttribute("soundplaying"), "Should not have the soundplaying attribute");
 
   yield play(tab);
 
   is(toggleMute.hasAttribute("muted"), expectMuted, "Should have the correct state for the muted attribute");
   ok(toggleMute.hasAttribute("soundplaying"), "Should have the soundplaying attribute");
--- a/browser/locales/en-US/chrome/browser/browser.properties
+++ b/browser/locales/en-US/chrome/browser/browser.properties
@@ -809,17 +809,17 @@ userContextNone.accesskey = N
 userContext.aboutPage.label = Manage containers
 userContext.aboutPage.accesskey = O
 
 userContextOpenLink.label = Open Link in New %S Tab
 
 muteTab.label = Mute Tab
 muteTab.accesskey = M
 unmuteTab.label = Unmute Tab
-unmuteTab.accesskey = M
+unmuteTab.accesskey = m
 playTab.label = Play Tab
 playTab.accesskey = l
 
 # LOCALIZATION NOTE (weakCryptoOverriding.message): %S is brandShortName
 weakCryptoOverriding.message = %S recommends that you don’t enter your password, credit card and other personal information on this website.
 revokeOverride.label = Don’t Trust This Website
 revokeOverride.accesskey = D