[OpenLayers-Dev] click & pinch overhaul
Tim Schaub
tschaub at opengeo.org
Mon Mar 7 10:56:23 EST 2011
Hey-
There are a number of issues with how the click and pinch handlers work
together. After adding pinch zoom, we lost the multi-touch click to
zoom out. In addition, the pinch handler was overly cautious about
stopping event propagation because the click handler wasn't particularly
good at distinguishing clicks from pinches. I've overhauled the click
handler to better distinguish clicks from pinches and resolved a number
of issues that came up along the way.
http://trac.osgeo.org/openlayers/ticket/3133
Andreas had reviewed this patch in a previous state, but there were
still some unhandled errors getting through, so I continued to modify it.
I'd appreciate it if people could test the changes on real devices (I've
only tested on emulators). To best test the changes, it is important to
have an error console enabled.
You should see double-click (zoom in), multi-touch click (zoom out), and
pinch (zoom/drag) working in this sandbox example (on multi-touch devices):
http://dev.openlayers.org/sandbox/tschaub/click/examples/mobile.html
You should also see no unhandled errors. However, there are currently
unhandled errors when dragging on the trunk (after r11635). I'll update
the sandbox when this is addressed.
http://trac.osgeo.org/openlayers/ticket/2936#comment:17
Thanks for help testing/reviewing.
Tim
--
Tim Schaub
OpenGeo - http://opengeo.org
Expert service straight from the developers.
More information about the Dev
mailing list