[OpenLayers-Users] associating events to geometries
Christopher Schmidt
crschmidt at metacarta.com
Mon Mar 19 07:30:48 EDT 2007
On Mon, Mar 19, 2007 at 11:40:22AM +0100, Eric Lemoine wrote:
> Hello
>
> I'd like to associate events to geometries. With the old vector branch
> I did that using
>
> feature.geometry.registerEventCallback('mouseover', null, callback);
>
> but the registerEventCallback() no longer exists in the new vector tree.
Have a look at http://openlayers.org/dev/examples/openmnnd.html , and
the SelectFeature control. (In this case, the 'move' callback).
(The reason for removing the handler directly on the geometries is that
it was creating objects which were significantly larger in memory. I
think the same things can be done with the SelectFeature handler. If
not, please explain, and we'll look into how to work with it.)
Regards,
--
Christopher Schmidt
MetaCarta
More information about the Users
mailing list