javascript - Open Layers 3 Zoom map event handler -


I have to handle a zoom event in Open Layer 3.

The following is my code: <[OSM_Staster, WFS_layer], view: view}) / p>

  map_object = new ol.Map ({target: 'map', control: control_list) , Interaction: interaction_list, overlay: [overlay]; Map_object.on ("zoom", function () {console.log ('zooming ...');});  

The code runs with no errors and shows a map, but there is no output in the console, so that this function is not firing.

Is:

  map_object.on ("drag", function () {console.log ('drag ...');});  

And this also does nothing.

How to handle map control incidents in Oll 3 will be some help (especially zooming!) Note I have 'zoom' as well as the law Has tried to 'zoom' for the area of ​​type.

levand Try with the event (see, and to see it in the "Top bar" Do not forget to uncheck »).


Comments

Popular posts from this blog

apache - 504 Gateway Time-out The server didn't respond in time. How to fix it? -

c# - .net WebSocket: CloseOutputAsync vs CloseAsync -

c++ - How to properly scale qgroupbox title with stylesheet for high resolution display? -