[OpenLayers-Dev] click & pinch overhaul

Tim Schaub tschaub at opengeo.org
Wed Mar 9 02:11:56 EST 2011


I've updated the sandbox with two changes:

1) Double click pixel tolerance is now 13.  This should give fewer 
ignored double clicks.

2) The pinch handler now stops the browser default behavior on handled 
touch move events.  This may stop the page drag on older iOS.

http://dev.openlayers.org/sandbox/tschaub/click/examples/mobile.html

I'm still unclear about whether the undesired page dragging only occurs 
in the sandbox example, or whether you also see it on the trunk.

Thanks for the testing & feedback.
Tim

On 3/8/11 2:08 PM, Cédric MOULLET wrote:
> Hi Tim,
> It's really a great function, and so fast !!!
> I put two answers inline,
> Cédric
>
> On Tue, Mar 8, 2011 at 8:48 AM, Tim Schaub <tschaub at opengeo.org
> <mailto:tschaub at opengeo.org>> wrote:
>
>     Thanks for the report Cédric.  Comments below.
>
>
>     On 3/7/11 10:49 AM, Cédric MOULLET wrote:
>
>         Hi Tim,
>
>         Thanks for these improvements. I have tested on several
>         plattforms (see
>         https://spreadsheets.google.com/ccc?key=0AjTbLQNm01pfdEtUc0FkVm9DYnBtMTNkcWpTemw3T0E&authkey=CJGm_vQF&hl=fr#gid=0
>         <https://spreadsheets.google.com/ccc?key=0AjTbLQNm01pfdEtUc0FkVm9DYnBtMTNkcWpTemw3T0E&authkey=CJGm_vQF&hl=fr#gid=0>
>         <https://spreadsheets.google.com/ccc?key=0AjTbLQNm01pfdEtUc0FkVm9DYnBtMTNkcWpTemw3T0E&authkey=CJGm_vQF&hl=fr#gid=0
>         <https://spreadsheets.google.com/ccc?key=0AjTbLQNm01pfdEtUc0FkVm9DYnBtMTNkcWpTemw3T0E&authkey=CJGm_vQF&hl=fr#gid=0>>).
>         I face the same issues like Steven. In addition, I have observed the
>         following things:
>         - iTouch 3.1.3: Pinch Zoom Dragging -> it moves the browser
>         instead of
>         the map and makes the function ineffective
>
>
>     I also saw the same on an iTouch before upgrading.  But I'm pretty
>     sure I saw it on the trunk (instead of just on this sandbox).  Are
>     you seeing the issue in this sandbox and not on the trunk?  (I've
>     only got access to an upgraded iTouch, and pinch zooming works there.)
>
>
> I have tested on your sandbox: Here is a small video that presents the
> issue:
> http://www.youtube.com/watch?v=6VoVKeOy9dg&feature=player_embedded
> <http://www.youtube.com/watch?v=6VoVKeOy9dg&feature=player_embedded>
> (sorry for the quality, but I'm not Spielberg). I can observe that the
> pinch function is working, but the browser window moves. I don't observe
> that on the iPad 4.2. If it's an iOS version issue, I don't think it's
> so important.
>
>
>
>         - Android Nexus S: the double click seems to work a bit better,
>         but has
>         still issues. No idea why (but this is a very empirical observation)
>
>
>     Sounds like the 10 pixel tolerance for double clicks may not be enough.
>
>     I'd be curious what you see for pixel displacement on typical
>     double-tap sequences (on a touch device).
>
>     http://dev.openlayers.org/sandbox/tschaub/click/examples/dpx.html
>
>
> I have added an average and standard deviation function:
> http://dev.openlayers.org/sandbox/cmoullet/openlayers/examples/dpx.html
>
> iTouch 3.1.3: pair: 30 - avg: 4.2 - std: 3.1
> iPad 4.2: pair 30 - avg 6.7 - std: 2.5
> Android Nexus S: pair 30 - avg: 8.3 - std: 4.5
>
> These are of course very empirical results, but it seems that I'm less
> precise on an Android nexus S. So the tolerance should be a bit bigger.


-- 
Tim Schaub
OpenGeo - http://opengeo.org
Expert service straight from the developers.


More information about the Dev mailing list