Hi Alexandre,<br><br>thanks for your reply! I tried using OpenLayers.Handler.Feature.prototype.clickTolerance=100/1000/1000000; , but it makes no difference. It does get stored, because when I do alert(OpenLayers.Handler.Feature.prototype.clickTolerance); it does show the correct value.<br>
<br>I also tried altering the clickTolerance in openlayers.js, but that didn't do anything either. <br><br>Thanks,<br><br>Alex.<br><br>Date: Tue, 03 Aug 2010 08:12:00 -0400<br>
From: Alexandre Dube <<a href="mailto:adube@mapgears.com" target="_blank">adube@mapgears.com</a>><br>
Subject: Re: [OpenLayers-Users] clickTolerance on selectFeature?<br>
To: <a href="mailto:users@openlayers.org" target="_blank">users@openlayers.org</a><br>
Message-ID: <<a href="mailto:4C580790.3030102@mapgears.com" target="_blank">4C580790.3030102@mapgears.com</a><div>><br>
Content-Type: text/plain; charset="iso-8859-1"<br>
<br>
Hi Alex,<br>
<br>
'clickTolerance' is a OpenLayers.Handler.Feature property. If you<br>
look in the Select.js file, you'll see that the handler is set inside<br>
the initialize method and that there is no way other than modifying the<br>
code there to set your own 'clickTolerance'. A thing you could do is to<br>
overwrite its default value to what you want but it will affect every<br>
other Controls that use it (do it before defining your SelectFeature<br>
control ) :<br>
<br>
OpenLayers.Handler.Feature.prototype.clickTolerance = 100;<br>
<br>
Try it and tell me if that worked for you.<br>
<br>
Kind regards,<br>
<br>
Alexandre<br>
<br>
<br>
On 10-08-02 04:40 PM, Alex Brandsen wrote:<br>
> Hi all,<br>
><br>
> is it possible to set the clickTolerance on a selectFeature control? I<br>
> can find the clickTolerance on the getFeature control :<br>
><br>
> (<a href="http://dev.openlayers.org/docs/files/OpenLayers/Control/GetFeature-js.html#OpenLayers.Control.GetFeature.clickTolerance" target="_blank">http://dev.openlayers.org/docs/files/OpenLayers/Control/GetFeature-js.html#OpenLayers.Control.GetFeature.clickTolerance</a>)<br>
><br>
> but not in the documentation of selectFeature. If I just try to add<br>
> "clickTolerance: 100" to the options array of selectFeature it has no<br>
> effect...<br>
><br>
> Thanks,<br>
><br>
> Alex.<br>
><br>
><br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@openlayers.org" target="_blank">Users@openlayers.org</a><br>
> <a href="http://openlayers.org/mailman/listinfo/users" target="_blank">http://openlayers.org/mailman/listinfo/users</a><br>
><br>
<br>
<br>
--<br>
Alexandre Dub?<br>
Mapgears<br>
<a href="http://www.mapgears.com/" target="_blank">www.mapgears.com</a></div>