diff --git a/devtools/client/locales/en-US/debugger.dtd b/devtools/client/locales/en-US/debugger.dtd | |
--- a/devtools/client/locales/en-US/debugger.dtd | |
+++ b/devtools/client/locales/en-US/debugger.dtd | |
@@ -162,16 +162,23 @@ | |
<!ENTITY debuggerUI.seMenuBreak.key "B"> | |
<!-- LOCALIZATION NOTE (debuggerUI.seMenuCondBreak): This is the text that | |
- appears in the source editor context menu for adding a conditional | |
- breakpoint. --> | |
<!ENTITY debuggerUI.seMenuCondBreak "Add Conditional Breakpoint"> | |
<!ENTITY debuggerUI.seMenuCondBreak.key "B"> | |
+<!-- LOCALIZATION NOTE (debuggerUI.seMenuCondBreak): This is the text that | |
+ - appears in the source editor context menu for editing a conditional | |
+ - breakpoint. --> | |
+<!ENTITY debuggerUI.seEditMenuCondBreak "Edit Conditional Breakpoint"> | |
+<!ENTITY debuggerUI.seEditMenuCondBreak.key "B"> | |
+ | |
+ | |
<!-- LOCALIZATION NOTE (debuggerUI.tabs.*): This is the text that | |
- appears in the debugger's side pane tabs. --> | |
<!ENTITY debuggerUI.tabs.workers "Workers"> | |
<!ENTITY debuggerUI.tabs.sources "Sources"> | |
<!ENTITY debuggerUI.tabs.traces "Traces"> | |
<!ENTITY debuggerUI.tabs.callstack "Call Stack"> | |
<!ENTITY debuggerUI.tabs.variables "Variables"> | |
<!ENTITY debuggerUI.tabs.events "Events"> | |
diff --git a/devtools/client/sourceeditor/editor.js b/devtools/client/sourceeditor/editor.js | |
--- a/devtools/client/sourceeditor/editor.js | |
+++ b/devtools/client/sourceeditor/editor.js | |
@@ -296,16 +296,26 @@ Editor.prototype = { | |
cm = win.CodeMirror(win.document.body, this.config); | |
cm.getWrapperElement().addEventListener("contextmenu", (ev) => { | |
ev.preventDefault(); | |
if (!this.config.contextMenu) return; | |
let popup = this.config.contextMenu; | |
if (typeof popup == "string") | |
popup = el.ownerDocument.getElementById(this.config.contextMenu); | |
+ | |
+ // this might not be the best way or place to access the menu item | |
+ var conditionalBreakpointMenuItem = popup.querySelector("#se-dbg-cMenu-addConditionalBreakpoint"); | |
+ | |
+ if (conditionalBreakpointMenuItem) { | |
+ // => change label... | |
+ // currently doesn't access Entity? | |
+ conditionalBreakpointMenuItem.label = "&debuggerUI.seEditMenuCondBreak;" | |
+ } | |
+ | |
popup.openPopupAtScreen(ev.screenX, ev.screenY, true); | |
}, false); | |
// Intercept the find and find again keystroke on CodeMirror, to avoid | |
// the browser's search | |
let findKey = L10N.GetStringFromName("find.commandkey"); | |
let findAgainKey = L10N.GetStringFromName("findAgain.commandkey"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment