1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 14:02:28 +01:00

Kludge to enable focusing the input field on Mac/MS

This commit is contained in:
Kris Maglione
2008-11-14 21:07:43 +00:00
parent 8bb3be2580
commit 257db25df2

View File

@@ -137,7 +137,12 @@ const modes = (function () //{{{
options.setPref("accessibility.browsewithcaret", false); options.setPref("accessibility.browsewithcaret", false);
statusline.updateUrl(); statusline.updateUrl();
// Kludge to prevent the input field losing focus on MS/Mac
setTimeout(function () {
let focus = document.commandDispatcher.focusedElement;
if (focus != document.getElementById("urlbar").inputField)
liberator.focusContent(false); liberator.focusContent(false);
}, 100);
} }
} }