[OpenLayers-Trac] [OpenLayers] #1293: SelectFeature conflicts with drag-to-zoom rectangle

OpenLayers trac at openlayers.org
Sun Feb 3 15:23:09 EST 2008


#1293: SelectFeature conflicts with drag-to-zoom rectangle
-----------------------+----------------------------------------------------
  Reporter:  elemoine  |       Owner:     
      Type:  feature   |      Status:  new
  Priority:  minor     |   Milestone:     
 Component:  general   |     Version:  SVN
Resolution:            |    Keywords:     
     State:            |  
-----------------------+----------------------------------------------------
Comment (by elemoine):

 I did a quick investigation on the problem.

 When the zoombox is drawn from left to right the target of the final
 mouseup event (evt.target) is the zoombox div, even if the mouseup occurs
 in a feature.

 When the zoombox is drawn from right to left the target of mouseup event
 is the svg element of the vector layer if the mouseup occurs outside of a
 feature, and it is the svg element of the feature if the mouseup occurs in
 a feature.

 I don't explain this.

 Thus, if the zoombox is drawn from right to left and the mouseup occurs in
 a feature, the mouseup event is handled by the feature handler which, by
 default, stops the event.

 See the attached patch (patch-1293-r5978-A0.diff) to the boxes-vector.html
 example for a workaround to the issue (only works with trunk).

-- 
Ticket URL: <http://trac.openlayers.org/ticket/1293#comment:1>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer


More information about the Trac mailing list