-
Notifications
You must be signed in to change notification settings - Fork 37
Events list
You can add your own handler for map-related events by calling setEventHandler on the OpenHeatMap component. This is the list of the possible events you can hook into, along with the circumstances they’re called in and information that’s passed.
Every handler function must return a value indicating whether the event should continue to be processed by the map component to implement its default behavior. If you didn’t want double-clicking on the map to zoom in for example, you’d attach an event to ‘doubleclick’ and return false. Note – a common bug is returning nothing from your event handler function, which resolves as false and so further processing of the event is abandoned. For example if your ‘click’ handler didn’t return anything then you would see the map failing to re-render as the user panned around by dragging the mouse. Make sure your handlers always return something.
click
datachange
doubleclick
error
framerender
mousedown
mouseout
mouseover
mouseup
valuesload
waysload