mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-21 23:57:59 +01:00
Kludge the stupid urlbar focus bug better
This commit is contained in:
@@ -116,13 +116,7 @@ const modes = (function () //{{{
|
||||
options.setPref("accessibility.browsewithcaret", false);
|
||||
|
||||
statusline.updateUrl();
|
||||
// Kludge to prevent the input field losing focus on MS/Mac
|
||||
setTimeout(function () {
|
||||
let focus = document.commandDispatcher.focusedElement;
|
||||
let urlbar = document.getElementById("urlbar");
|
||||
if (!urlbar || focus != urlbar.inputField)
|
||||
liberator.focusContent(false);
|
||||
}, 0);
|
||||
liberator.focusContent(false);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -137,6 +131,8 @@ const modes = (function () //{{{
|
||||
|
||||
get all() mainModes.slice(),
|
||||
|
||||
get inputMode() main & (this.COMMAND_LINE | this.INPUT | this.TEXTAREA | this.COMPOSE),
|
||||
|
||||
addMode: function (name, extended, display) {
|
||||
let disp = name.replace("_", " ", "g");
|
||||
this[name] = 1 << lastMode++;
|
||||
|
||||
Reference in New Issue
Block a user