Don't focus the text area on touch devices to avoid flashing the keyboard

Currently the keyboard slide out & hides again quickly.
This commit is contained in:
Leo Koppelkamm 2013-05-12 18:49:07 +02:00 committed by Tom Hughes
parent b6b9052c37
commit 8255553e97

View file

@ -46,9 +46,12 @@ $(document).ready(function () {
}
});
map.on("popupopen", function (e) {
$(e.popup._container).find(".comment").focus();
});
// Don't focus the text area on touch devices to avoid flashing the keyboard
if (!('ontouchstart' in document.documentElement)) {
map.on("popupopen", function (e) {
$(e.popup._container).find(".comment").focus();
});
}
map.on("popupclose", function (e) {
if (newNote && e.popup == newNote._popup) {