Bug 1678638 - [devtools] Remove unused node parameter from PausedDebuggerOverlay#show. r=ladybenko.

This was probably here to match other highlighters, but
we're not using it at all so let's remove it.

Differential Revision: https://phabricator.services.mozilla.com/D97777
This commit is contained in:
Nicolas Chevobbe 2020-12-01 09:17:09 +00:00
Родитель a2b5bca947
Коммит 41f54d06bf
3 изменённых файлов: 6 добавлений и 7 удалений

Просмотреть файл

@ -201,14 +201,13 @@ PausedDebuggerOverlay.prototype = {
return this.markup.getElement(this.ID_CLASS_PREFIX + id);
},
show(node, options = {}) {
if (this.env.isXUL || !options.reason) {
show(reason) {
if (this.env.isXUL || !reason) {
return false;
}
let reason;
try {
reason = L10N.getStr(`whyPaused.${options.reason}`);
reason = L10N.getStr(`whyPaused.${reason}`);
} catch (e) {
// This is a temporary workaround to be uplifted to Firefox 71.
// This actors relies on a client side properties file. This file will not

Просмотреть файл

@ -498,7 +498,7 @@ const ThreadActor = ActorClassWithSpec(threadSpec, {
) {
const reason = this._priorPause.why.type;
await this.pauseOverlay.isReady;
this.pauseOverlay.show(null, { reason });
this.pauseOverlay.show(reason);
}
},

Просмотреть файл

@ -54,7 +54,7 @@ window.onload = async function() {
ok(isHidden("root"), "The highlighter is hidden");
info("Show the highlighter with overlay and toolbar");
let didShow = highlighter.show(null, { "reason": "breakpoint" });
let didShow = highlighter.show("breakpoint");
ok(didShow, "Calling show returned true");
ok(!isHidden("root"), "The highlighter is shown");
ok(isOverlayShown(), "The overlay is shown");
@ -65,7 +65,7 @@ window.onload = async function() {
);
info("Call show again with another reason");
didShow = highlighter.show(null, {"reason": "debuggerStatement"});
didShow = highlighter.show("debuggerStatement");
ok(didShow, "Calling show returned true too");
ok(!isHidden("root"), "The highlighter is still shown");
is(getReason(), "Paused on debugger statement",