Keep map focus after zoom animation end

When we had focus and cursor in the document and we click
zoom in/out on the statusbar on the desktop - in result we lost
focus and we cannot type.

Zoom animation disabled textarea used for input so it loses focus.
This change restores focus for it after animation end.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I4c1a5f4b806968c7fdd4c6acde90d5d6450be5a1
This commit is contained in:
Szymon Kłos 2021-10-18 14:23:00 +02:00 committed by Szymon Kłos
parent ee06e08f6c
commit a2543104ab

View file

@ -729,6 +729,7 @@ L.TileSectionManager = L.Class.extend({
painter.setWaitForTiles(false);
painter._sectionContainer.setZoomChanged(false);
map.enableTextInput();
map.focus(map.canAcceptKeyboardInput());
// Paint everything.
painter._sectionContainer.requestReDraw();
// Don't let a subsequent pinchZoom start before finishing all steps till this point.