This is a migrated thread and some comments may be shown as answers.

OnClick fired when clicking on zoom buttons

2 Answers 55 Views
Map
This is a migrated thread and some comments may be shown as answers.
Warnestam
Top achievements
Rank 1
Warnestam asked on 02 Oct 2017, 09:44 AM

Hi,

We are placing markers when the user clicks on the map. A problem is that the OnClick event is also fired when the user clicks on one of the zoom-buttons (but not on one of the pan-buttons). 

Is there anyway to separate a button click from a normal click? Alternative solutions could be using right clicks or even click/drag a marker itself.

 

Kind regards

Robert

 

2 Answers, 1 is accepted

Sort by
0
Accepted
Peter
Top achievements
Rank 1
answered on 05 Oct 2017, 08:31 AM

Hi Robert, 

You can prevent the click event when the target of the click is inside the zoom control. Here is a dojo example that demonstrates the suggested approach using the underlying Kendo UI Map.

0
Warnestam
Top achievements
Rank 1
answered on 05 Oct 2017, 08:34 AM

Thanks! That will help us. Still think it should be considered as a bug.

Regards

Robert

Tags
Map
Asked by
Warnestam
Top achievements
Rank 1
Answers by
Peter
Top achievements
Rank 1
Warnestam
Top achievements
Rank 1
Share this question
or