[OpenLayers-Users] distinguish "click" from "drag"

Bobby Braswell rob.braswell at unh.edu
Tue Apr 17 15:19:02 EDT 2007


Hi-

I'd like to trigger certain events (e.g., display feature info) when  
the map is clicked, but not dragged. I'd like to do other things (or  
perhaps nothing special) when then map is dragged. Currently I am  
using map.events.register('click', map, function (e) {..}); and that  
works fine except for the undesirable behavior of showing feature  
info when the user simply wants to move the map around.

Is there a way to register an event for click but somehow cancel it  
if there is a subsequent drag before the mouseup?

Thanks very much,
Rob Braswell


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20070417/59f4fd90/attachment.html


More information about the Users mailing list