[OpenLayers-Trac] Re: [OpenLayers] #3079: Zoom in not working in Sencha touch example

OpenLayers trac-20090302 at openlayers.org
Tue Feb 22 05:51:10 EST 2011

#3079: Zoom in not working in Sencha touch example
 Reporter:  bartvde   |       Owner:  bartvde     
     Type:  bug       |      Status:  new         
 Priority:  minor     |   Milestone:  2.11 Release
Component:  examples  |     Version:  2.10        
 Keywords:            |       State:              

Comment(by bartvde):

 So Sencha Touch is simulating a click event which is messing things up:


     fireTapEvent: function(e, info) {
         this.fire('tap', e, info);

         if (e.event)
             e = e.event;

         var target = (e.changedTouches ? e.changedTouches[0] : e).target;

         if (!target.disabled && this.fireClickEvent) {
             var clickEvent = document.createEvent("MouseEvent");
                 clickEvent.initMouseEvent('click', e.bubbles,
 e.cancelable, document.defaultView, e.detail, e.screenX, e.screenY,
                                          e.clientY, e.ctrlKey, e.altKey,
 e.shiftKey, e.metaKey, e.metaKey, e.button, e.relatedTarget);
                 clickEvent.isSimulated = true;


 Talked with Tim and Eric, and we decided on setting a flag in the click
 handler when touchstart comes in so we ignore click in on touch enabled

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

More information about the Trac mailing list