Re: [OpenMap Users] Switching between layers ...

From: Don Dietrick <dietrick_at_bbn.com>
Date: Tue, 12 Feb 2008 16:47:17 -0500

Hi Faly,

You can control when your OMGraphics are editable in a Layer. In an
OMGraphicHandlerLayer, where the mouse events are handled at a higher
level for you, the layer gets asked if an OMGraphic is selectable. If
it's not, then it is un-editable. You can have your button switch how
that question is answered. I recommend playing around with the
DemoLayer for a better idea of the how the threading works on this,
and you can modify the layer to implement the Tool interface,
returning JButtons from the getFace() method. Those buttons will be
placed on the toolbar above the map.

Hope this helps,

Don


On Feb 11, 2008, at 4:09 AM, Le-Faly wrote:

> Hi folks,
>
> Is it possible to switch data between editable and not-editable
> layers? In particular, I would like to make editable all OMgraphics
> of a layer, via a click in a JButton named "Edit" and make them non-
> editable again via a click in a JButton named "Display only".
>
> Thanks for any help.
>
> Faly
>
> Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers
> Yahoo! Mail

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Don Dietrick, dietrick_at_bbn.com
BBN Technologies, Cambridge MA
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=



--
[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Tue Feb 12 2008 - 16:47:27 EST

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:09 EDT