loleaflet/src/map/Map.js | 4 ++++ 1 file changed, 4 insertions(+) New commits: commit e35fe1c826d2507848ffaaae8a2bcd1ebb6ca031 Author: Pranav Kant <pran...@collabora.co.uk> Date: Thu Dec 22 15:46:48 2016 +0530
loleaflet: Focus on textarea after map activation So that user does not have to click again into the document to start typing. Change-Id: Iaf1993a9a331ab86c668e718fae5f6a727c120cc diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js index a04b654..4001cd4 100644 --- a/loleaflet/src/map/Map.js +++ b/loleaflet/src/map/Map.js @@ -567,7 +567,9 @@ L.Map = L.Evented.extend({ }, focus: function () { + console.debug('focus:'); if (this._docLayer && document.activeElement !== this._docLayer._textArea) { + console.debug('focus: focussing'); this._docLayer._textArea.focus(); } }, @@ -754,6 +756,7 @@ L.Map = L.Evented.extend({ var id = vex.dialogID; vex.dialogID = -1; this._startInactiveTimer(); + this.focus(); return vex.close(id); } } else { @@ -762,6 +765,7 @@ L.Map = L.Evented.extend({ } this._startInactiveTimer(); + this.focus(); return false; }, _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits