[OpenLayers-Trac] [OpenLayers] #341: Mouse wheel scroll should zoom in/out over mouse pointer location

OpenLayers trac at openlayers.org
Fri Mar 23 13:07:45 EDT 2007


#341: Mouse wheel scroll should zoom in/out over mouse pointer location
------------------------------------+---------------------------------------
  Reporter:  sderle                 |       Owner:  sderle     
      Type:  feature                |      Status:  new        
  Priority:  minor                  |   Milestone:  2.4 Release
 Component:  Control.MouseDefaults  |     Version:             
Resolution:                         |    Keywords:             
------------------------------------+---------------------------------------
Changes (by sderle):

  * status:  assigned => new

Comment:

 During the hack week, I ran right past this comment (extracted from
 MouseDefaults.js into Handler/MouseWheel.js) without paying any attention
 to it:

   // add the mouse position to the event because mozilla has a bug

   // with clientX and clientY (see
 https://bugzilla.mozilla.org/show_bug.cgi?id=352179)

   // getLonLatFromViewPortPx(e) returns wrong values

 Caching the mouse location on mouse move works around this -- in fact,
 this is what MouseDefaults used to do, only it's done in the MouseWheel
 handler now. Also fixed the math in Control.Navigation. See the attached
 patch.

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


More information about the Trac mailing list