From 05c0b37789a08faf212f90dbd55e50cbca47e8e9 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Thu, 27 Sep 2018 11:48:12 +0200 Subject: Fix inappropriate close of detail --- chimere/static/chimere/js/jquery.chimere.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/chimere/static/chimere/js/jquery.chimere.js b/chimere/static/chimere/js/jquery.chimere.js index 64f18e0..cb030e7 100644 --- a/chimere/static/chimere/js/jquery.chimere.js +++ b/chimere/static/chimere/js/jquery.chimere.js @@ -604,7 +604,8 @@ function transformCoordToLonLat(coord) { ); $("#" + map_id + "_hover").show(); } - if (settings[map_id].mouse_hover_opened != pk){ + if (settings[map_id].mouse_hover_opened != pk && + !settings[map_id].current_feature){ settings[map_id].mouse_hover_opened = pk; if ($('.popover-content').is(':visible')){ $(settings[map_id].popup_item).popover('destroy'); @@ -618,7 +619,8 @@ function transformCoordToLonLat(coord) { } } else { - if (settings[map_id].mouse_hover_opened){ + if (settings[map_id].mouse_hover_opened && + !settings[map_id].current_feature){ settings[map_id].mouse_hover_opened = null; if ($('.popover-content').is(':visible')){ $(settings[map_id].popup_item).popover('destroy'); -- cgit v1.2.3