зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1266134 - Prevent browser_computed_keybindings_01.js from opening options panel. r=jryans
MozReview-Commit-ID: LXCWjQwkwUN --HG-- extra : rebase_source : 97e106007719319a1214b16ae29be707fcf2e7e7
This commit is contained in:
Родитель
7c35371232
Коммит
55a228567f
|
@ -939,6 +939,9 @@ PropertyView.prototype = {
|
||||||
});
|
});
|
||||||
this.shortcuts.on("F1", (name, event) => {
|
this.shortcuts.on("F1", (name, event) => {
|
||||||
this.mdnLinkClick(event);
|
this.mdnLinkClick(event);
|
||||||
|
// Prevent opening the options panel
|
||||||
|
event.preventDefault();
|
||||||
|
event.stopPropagation();
|
||||||
});
|
});
|
||||||
this.shortcuts.on("Return", (name, event) => this.onMatchedToggle(event));
|
this.shortcuts.on("Return", (name, event) => this.onMatchedToggle(event));
|
||||||
this.shortcuts.on("Space", (name, event) => this.onMatchedToggle(event));
|
this.shortcuts.on("Space", (name, event) => this.onMatchedToggle(event));
|
||||||
|
@ -1170,8 +1173,6 @@ PropertyView.prototype = {
|
||||||
let browserWin = inspector.target.tab.ownerDocument.defaultView;
|
let browserWin = inspector.target.tab.ownerDocument.defaultView;
|
||||||
browserWin.openUILinkIn(this.link, "tab");
|
browserWin.openUILinkIn(this.link, "tab");
|
||||||
}
|
}
|
||||||
event.preventDefault();
|
|
||||||
event.stopPropagation();
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -73,7 +73,7 @@ function checkHelpLinkKeybinding(view) {
|
||||||
let def = defer();
|
let def = defer();
|
||||||
|
|
||||||
let propView = getFirstVisiblePropertyView(view);
|
let propView = getFirstVisiblePropertyView(view);
|
||||||
propView.mdnLinkClick = function () {
|
propView.mdnLinkClick = function (event) {
|
||||||
ok(true, "Pressing F1 opened the MDN link");
|
ok(true, "Pressing F1 opened the MDN link");
|
||||||
def.resolve();
|
def.resolve();
|
||||||
};
|
};
|
||||||
|
|
Загрузка…
Ссылка в новой задаче