зеркало из https://github.com/mozilla/gecko-dev.git
Backed out changeset 4d19ea5594d2 (bug 1635548) for assertion failures on ErrorResult.h. CLOSED TREE
This commit is contained in:
Родитель
2dcfa8f525
Коммит
39a0f07a9d
|
@ -61,10 +61,12 @@
|
|||
disabled="true"
|
||||
data-l10n-id="text-action-spell-no-suggestions"/>
|
||||
<menuitem id="spell-add-to-dictionary"
|
||||
data-l10n-id="text-action-spell-add-to-dictionary"
|
||||
label="&spellAddToDictionary.label;"
|
||||
accesskey="&spellAddToDictionary.accesskey;"
|
||||
oncommand="InlineSpellCheckerUI.addToDictionary();"/>
|
||||
<menuitem id="spell-undo-add-to-dictionary"
|
||||
data-l10n-id="text-action-spell-undo-add-to-dictionary"
|
||||
label="&spellUndoAddToDictionary.label;"
|
||||
accesskey="&spellUndoAddToDictionary.accesskey;"
|
||||
oncommand="InlineSpellCheckerUI.undoAddToDictionary();" />
|
||||
<menuseparator id="spell-suggestions-separator"/>
|
||||
<menuitem id="context-openlinkincurrent"
|
||||
|
@ -72,7 +74,7 @@
|
|||
oncommand="gContextMenu.openLinkInCurrent();"/>
|
||||
# label and data-usercontextid are dynamically set.
|
||||
<menuitem id="context-openlinkincontainertab"
|
||||
data-l10n-id="main-context-menu-open-link-in-container-tab"
|
||||
accesskey="&openLinkCmdInTab.accesskey;"
|
||||
oncommand="gContextMenu.openLinkInTab(event);"/>
|
||||
<menuitem id="context-openlinkintab"
|
||||
data-l10n-id="main-context-menu-open-link-new-tab"
|
||||
|
@ -359,18 +361,22 @@
|
|||
</menu>
|
||||
<menuseparator id="spell-separator"/>
|
||||
<menuitem id="spell-check-enabled"
|
||||
data-l10n-id="text-action-spell-check-toggle"
|
||||
label="&spellCheckToggle.label;"
|
||||
type="checkbox"
|
||||
accesskey="&spellCheckToggle.accesskey;"
|
||||
oncommand="InlineSpellCheckerUI.toggleEnabled(window);"/>
|
||||
<menuitem id="spell-add-dictionaries-main"
|
||||
data-l10n-id="text-action-spell-add-dictionaries"
|
||||
label="&spellAddDictionaries.label;"
|
||||
accesskey="&spellAddDictionaries.accesskey;"
|
||||
oncommand="gContextMenu.addDictionaries();"/>
|
||||
<menu id="spell-dictionaries"
|
||||
data-l10n-id="text-action-spell-dictionaries">
|
||||
label="&spellDictionaries.label;"
|
||||
accesskey="&spellDictionaries.accesskey;">
|
||||
<menupopup id="spell-dictionaries-menu">
|
||||
<menuseparator id="spell-language-separator"/>
|
||||
<menuitem id="spell-add-dictionaries"
|
||||
data-l10n-id="text-action-spell-add-dictionaries"
|
||||
label="&spellAddDictionaries.label;"
|
||||
accesskey="&spellAddDictionaries.accesskey;"
|
||||
oncommand="gContextMenu.addDictionaries();"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
|
|
@ -394,13 +394,11 @@ class nsContextMenu {
|
|||
var label = ContextualIdentityService.getUserContextLabel(
|
||||
this.contentData.userContextId
|
||||
);
|
||||
|
||||
document.l10n.setAttributes(
|
||||
item,
|
||||
"main-context-menu-open-link-in-container-tab",
|
||||
{
|
||||
containerName: label,
|
||||
}
|
||||
item.setAttribute(
|
||||
"label",
|
||||
gBrowserBundle.formatStringFromName("userContextOpenLink.label", [
|
||||
label,
|
||||
])
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -443,9 +443,3 @@ main-context-menu-inspect-a11y-properties =
|
|||
main-context-menu-eme-learn-more =
|
||||
.label = Learn more about DRM…
|
||||
.accesskey = D
|
||||
|
||||
# Variables
|
||||
# $containerName (String): The name of the current container
|
||||
main-context-menu-open-link-in-container-tab =
|
||||
.label = Open Link in New { $containerName } Tab
|
||||
.accesskey = T
|
||||
|
|
|
@ -97,6 +97,8 @@ this container is a toolbar. This avoids double-speaking. -->
|
|||
<!ENTITY searchInput.placeholder "Search">
|
||||
<!ENTITY searchIcon.tooltip "Search">
|
||||
|
||||
<!ENTITY openLinkCmdInTab.accesskey "T">
|
||||
|
||||
<!ENTITY fullZoom.label "Zoom">
|
||||
|
||||
<!ENTITY sidebarCloseButton.tooltip "Close sidebar">
|
||||
|
@ -108,6 +110,9 @@ this container is a toolbar. This avoids double-speaking. -->
|
|||
<!ENTITY editPopupSettings.label "Edit Pop-up Blocker Options…">
|
||||
<!ENTITY editPopupSettings.accesskey "E">
|
||||
|
||||
<!ENTITY spellAddDictionaries.label "Add Dictionaries…">
|
||||
<!ENTITY spellAddDictionaries.accesskey "A">
|
||||
|
||||
<!-- Name for the tabs toolbar as spoken by screen readers.
|
||||
The word "toolbar" is appended automatically and should not be contained below! -->
|
||||
<!ENTITY tabsToolbar.label "Browser tabs">
|
||||
|
|
|
@ -892,6 +892,8 @@ 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
|
||||
|
|
|
@ -1,83 +0,0 @@
|
|||
# coding=utf8
|
||||
|
||||
# Any copyright is dedicated to the Public Domain.
|
||||
# http://creativecommons.org/publicdomain/zero/1.0/
|
||||
|
||||
from __future__ import absolute_import
|
||||
import fluent.syntax.ast as FTL
|
||||
from fluent.migrate.helpers import transforms_from, VARIABLE_REFERENCE
|
||||
from fluent.migrate import REPLACE, COPY
|
||||
|
||||
|
||||
def migrate(ctx):
|
||||
"""Bug 1635548 - Migrate browser-context.inc to Fluent, part {index}"""
|
||||
target = "toolkit/toolkit/global/textActions.ftl"
|
||||
reference = "toolkit/toolkit/global/textActions.ftl"
|
||||
ctx.add_transforms(
|
||||
target,
|
||||
reference,
|
||||
transforms_from(
|
||||
"""
|
||||
text-action-spell-add-to-dictionary =
|
||||
.label = { COPY(from_path, "spellAddToDictionary.label") }
|
||||
.accesskey = { COPY(from_path, "spellAddToDictionary.accesskey") }
|
||||
|
||||
text-action-spell-undo-add-to-dictionary =
|
||||
.label = { COPY(from_path, "spellUndoAddToDictionary.label") }
|
||||
.accesskey = { COPY(from_path, "spellUndoAddToDictionary.accesskey") }
|
||||
|
||||
text-action-spell-check-toggle =
|
||||
.label = { COPY(from_path, "spellCheckToggle.label") }
|
||||
.accesskey = { COPY(from_path, "spellCheckToggle.accesskey") }
|
||||
|
||||
text-action-spell-dictionaries =
|
||||
.label = { COPY(from_path, "spellDictionaries.label") }
|
||||
.accesskey = { COPY(from_path, "spellDictionaries.accesskey") }
|
||||
""",
|
||||
from_path="toolkit/chrome/global/textcontext.dtd",
|
||||
),
|
||||
)
|
||||
|
||||
target = "toolkit/toolkit/global/textActions.ftl"
|
||||
reference = "toolkit/toolkit/global/textActions.ftl"
|
||||
ctx.add_transforms(
|
||||
target,
|
||||
reference,
|
||||
transforms_from(
|
||||
"""
|
||||
text-action-spell-add-dictionaries =
|
||||
.label = { COPY(from_path, "spellAddDictionaries.label") }
|
||||
.accesskey = { COPY(from_path, "spellAddDictionaries.accesskey") }
|
||||
""",
|
||||
from_path="browser/chrome/browser/browser.dtd",
|
||||
),
|
||||
)
|
||||
|
||||
target = "browser/browser/browserContext.ftl"
|
||||
reference = "browser/browser/browserContext.ftl"
|
||||
ctx.add_transforms(
|
||||
target,
|
||||
reference,
|
||||
[
|
||||
FTL.Message(
|
||||
id=FTL.Identifier("main-context-menu-open-link-in-container-tab"),
|
||||
attributes=[
|
||||
FTL.Attribute(
|
||||
FTL.Identifier("label"),
|
||||
REPLACE(
|
||||
"browser/chrome/browser/browser.properties",
|
||||
"userContextOpenLink.label",
|
||||
{"%1$S": VARIABLE_REFERENCE("containerName")},
|
||||
),
|
||||
),
|
||||
FTL.Attribute(
|
||||
FTL.Identifier("accesskey"),
|
||||
COPY(
|
||||
"browser/chrome/browser/browser.dtd",
|
||||
"openLinkCmdInTab.accesskey",
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
)
|
|
@ -40,14 +40,14 @@
|
|||
this.spellcheck = MozXULElement.parseXULToFragment(
|
||||
`
|
||||
<menupopup class="textbox-contextmenu">
|
||||
<menuitem data-l10n-id="text-action-spell-no-suggestions" anonid="spell-no-suggestions" disabled="true"></menuitem>
|
||||
<menuitem data-l10n-id="text-action-spell-add-to-dictionary" anonid="spell-add-to-dictionary" oncommand="this.parentNode.parentNode.spellCheckerUI.addToDictionary();"></menuitem>
|
||||
<menuitem data-l10n-id="text-action-spell-undo-add-to-dictionary" anonid="spell-undo-add-to-dictionary" oncommand="this.parentNode.parentNode.spellCheckerUI.undoAddToDictionary();"></menuitem>
|
||||
<menuitem label="&spellNoSuggestions.label;" anonid="spell-no-suggestions" disabled="true"></menuitem>
|
||||
<menuitem label="&spellAddToDictionary.label;" accesskey="&spellAddToDictionary.accesskey;" anonid="spell-add-to-dictionary" oncommand="this.parentNode.parentNode.spellCheckerUI.addToDictionary();"></menuitem>
|
||||
<menuitem label="&spellUndoAddToDictionary.label;" accesskey="&spellUndoAddToDictionary.accesskey;" anonid="spell-undo-add-to-dictionary" oncommand="this.parentNode.parentNode.spellCheckerUI.undoAddToDictionary();"></menuitem>
|
||||
<menuseparator anonid="spell-suggestions-separator"></menuseparator>
|
||||
${this.editMenuItems}
|
||||
<menuseparator anonid="spell-check-separator"></menuseparator>
|
||||
<menuitem data-l10n-id="text-action-spell-check-toggle" type="checkbox" anonid="spell-check-enabled" oncommand="this.parentNode.parentNode.spellCheckerUI.toggleEnabled();"></menuitem>
|
||||
<menu data-l10n-id="text-action-spell-dictionaries" anonid="spell-dictionaries">
|
||||
<menuitem label="&spellCheckToggle.label;" type="checkbox" accesskey="&spellCheckToggle.accesskey;" anonid="spell-check-enabled" oncommand="this.parentNode.parentNode.spellCheckerUI.toggleEnabled();"></menuitem>
|
||||
<menu label="&spellDictionaries.label;" accesskey="&spellDictionaries.accesskey;" anonid="spell-dictionaries">
|
||||
<menupopup anonid="spell-dictionaries-menu" onpopupshowing="event.stopPropagation();" onpopuphiding="event.stopPropagation();"></menupopup>
|
||||
</menu>
|
||||
</menupopup>
|
||||
|
|
|
@ -2,4 +2,14 @@
|
|||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||||
|
||||
<!ENTITY spellAddToDictionary.label "Add to Dictionary">
|
||||
<!ENTITY spellAddToDictionary.accesskey "o">
|
||||
<!ENTITY spellUndoAddToDictionary.label "Undo Add To Dictionary">
|
||||
<!ENTITY spellUndoAddToDictionary.accesskey "n">
|
||||
<!ENTITY spellCheckToggle.label "Check Spelling">
|
||||
<!ENTITY spellCheckToggle.accesskey "g">
|
||||
<!ENTITY spellNoSuggestions.label "(No Spelling Suggestions)">
|
||||
<!ENTITY spellDictionaries.label "Languages">
|
||||
<!ENTITY spellDictionaries.accesskey "l">
|
||||
|
||||
<!ENTITY searchTextBox.clear.label "Clear">
|
||||
|
|
|
@ -50,23 +50,3 @@ text-action-select-all-shortcut =
|
|||
|
||||
text-action-spell-no-suggestions =
|
||||
.label = No Spelling Suggestions
|
||||
|
||||
text-action-spell-add-to-dictionary =
|
||||
.label = Add to Dictionary
|
||||
.accesskey = o
|
||||
|
||||
text-action-spell-undo-add-to-dictionary =
|
||||
.label = Undo Add To Dictionary
|
||||
.accesskey = n
|
||||
|
||||
text-action-spell-check-toggle =
|
||||
.label = Check Spelling
|
||||
.accesskey = g
|
||||
|
||||
text-action-spell-add-dictionaries =
|
||||
.label = Add Dictionaries…
|
||||
.accesskey = A
|
||||
|
||||
text-action-spell-dictionaries =
|
||||
.label = Languages
|
||||
.accesskey = L
|
||||
|
|
Загрузка…
Ссылка в новой задаче