After creating your interactor object, you need to add it through the interaction service :
JMap.Map.Interaction.addInteractor( "display-bubbles-on-click", // interactor id bubbleInteractor, // interactor object true// if true activate the interactor after being added )
There is always an interactor actived, and this is the active interactions that are in use on the map.
When you activate an interactor, the previous one is deactivated, and the new one activated on the map.
When you don't need anymore an interactor you can terminate it, and it will not exist anymore in the JMap Cloud NG Core library.
JMap.Map.Interaction
We introduced a notion of map interactor in JMap.
The need is that we want the map to interact in different ways depending on what the user is doing :
So we defined our own map interactors for JMap, and we also allow you to create and register your own interactors.
An interactor is a JS object that define 4 functions (for more details consult interface JMapInteractor) :
After creating your interactor object, you need to add it through the interaction service :
There is always an interactor actived, and this is the active interactions that are in use on the map.
When you activate an interactor, the previous one is deactivated, and the new one activated on the map.
When you don't need anymore an interactor you can terminate it, and it will not exist anymore in the JMap Cloud NG Core library.