loleaflet/src/layer/marker/TextInput.js | 3 +++ loleaflet/src/map/Map.js | 7 +------ 2 files changed, 4 insertions(+), 6 deletions(-)
New commits: commit 0064cfff56c9492ba063a033ead11f01078f198e Author: Henry Castro <hcas...@collabora.com> AuthorDate: Wed Jan 8 11:02:53 2020 -0400 Commit: Henry Castro <hcas...@collabora.com> CommitDate: Wed Jan 8 18:22:11 2020 +0100 loleaflet: simplify the function related to map focus Change-Id: I0849ad3a5abe50aaba3b993f6851c113b1bb27cb Reviewed-on: https://gerrit.libreoffice.org/c/online/+/86440 Reviewed-by: Henry Castro <hcas...@collabora.com> Tested-by: Henry Castro <hcas...@collabora.com> diff --git a/loleaflet/src/layer/marker/TextInput.js b/loleaflet/src/layer/marker/TextInput.js index 22b904632..ec431c267 100644 --- a/loleaflet/src/layer/marker/TextInput.js +++ b/loleaflet/src/layer/marker/TextInput.js @@ -118,6 +118,9 @@ L.TextInput = L.Layer.extend({ // Focus the textarea/contenteditable focus: function() { + // Clicking or otherwise focusing the map should focus on the clipboard + // container in order for the user to input text (and on-screen keyboards + // to pop-up), unless the document is read only. if (this._map._permission !== 'edit') { console.log('EPIC HORRORS HERE'); return; diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js index ef557f6c1..d0f571564 100644 --- a/loleaflet/src/map/Map.js +++ b/loleaflet/src/map/Map.js @@ -893,12 +893,7 @@ L.Map = L.Evented.extend({ }, focus: function () { - // Clicking or otherwise focusing the map should focus on the clipboard - // container in order for the user to input text (and on-screen keyboards - // to pop-up), unless the document is read only. - if (this._permission === 'edit') { - this._textInput.focus(); - } + this._textInput.focus(); }, hasFocus: function () { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits