[udig-devel] SelectionListener Problem
Jesse Eichar
jeichar at refractions.net
Fri Aug 10 10:16:39 PDT 2007
If you select a feature with the edit tool it is possible that it
doesn't fire a selection event. I think I changed this for RC11.
Jesse
On Aug 10, 2007, at 7:20 AM, Lucas, Michael wrote:
> I am having a similar problem, I tried to instantiate an
> ILayerListener in my plugin and tried to trap the selection event
> with the following statement:
> if(event.getType()==LayerEvent.EventType.FILTER)
>
> But, when selecting a feature, the listener code never seems to be
> executing. Is there anything else I need to do to plug the
> listener into uDig so it picks up the selection event? Or is there
> any sample code out there that listens for selection tool events?
>
> thanks!
>
> -Mike
>
>
> From: udig-devel-bounces at lists.refractions.net [mailto:udig-devel-
> bounces at lists.refractions.net] On Behalf Of Jesse Eichar
> Sent: Wednesday, July 25, 2007 11:55 AM
> To: User-friendly Desktop Internet GIS
> Subject: Re: [udig-devel] SelectionListener Problem
>
> Hi,
>
> The selection listener API hasn't been fully integrated with the
> rest of the platform yet. So you have to use ILayerListeners and
> listen for Filter events. When something is selected the filter
> that represents that selection is set on the layer where the
> selection occurred. That layer is typically the currently selected
> layer so you can either listen to all layers or have a
> IEditManagerListener that listens to layer selection events and
> retargets your listener each time the selected layer changes.
>
> Jesse
>
>
> On Jul 25, 2007, at 3:17 AM, Robineau Peter wrote:
>
>> Hi,
>>
>> is there a way to track selection of features in a layer?
>> I want to do some operations in a plugin when a new feature is
>> selected...
>>
>> Is there an easy-to-handle listener comparable with the
>> ShellListener? Just found SelectionListener (okay, sounds good...),
>> but don't know how to handle it properly....
>>
>>
>> thanks a lot,
>>
>> Peter
>>
>> _______________________________________________
>> User-friendly Desktop Internet GIS (uDig)
>> http://udig.refractions.net
>> http://lists.refractions.net/mailman/listinfo/udig-devel
>
> _______________________________________________
> User-friendly Desktop Internet GIS (uDig)
> http://udig.refractions.net
> http://lists.refractions.net/mailman/listinfo/udig-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.refractions.net/pipermail/udig-devel/attachments/20070810/a0363f25/attachment.html
More information about the udig-devel
mailing list