Skip to main content



      Home
Home » Eclipse Projects » GEF » Disallow certain Edit Part to be drop to a Contanier
Disallow certain Edit Part to be drop to a Contanier [message #69004] Mon, 10 March 2003 11:50 Go to next message
Eclipse UserFriend
Hi,
Is it possible to disallow certain Edit Part to be drop to a Container? If
yes, could you please tell me how to achieve that?

e.g. I would like to change the Circuit to allow user to drop a AND gate
figure, but NOT a OR gate figure. It will show a Stop sign icon when I
select a OR GATE figure and move it over to Circuit and when I move the
cursor to a other container (e.g. Flow Container), it should a Drop icon and
I can add the OR gate to the Flow Container?

Thanks
Re: Disallow certain Edit Part to be drop to a Contanier [message #69071 is a reply to message #69004] Mon, 10 March 2003 13:29 Go to previous message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

> Hi,
> Is it possible to disallow certain Edit Part to be drop to a Container? If
> yes, could you please tell me how to achieve that?

Yes, your layout editpolicy would override either getTarget(Request), if you
want that container to not be targeted, or getCommand(Request), if you want
the container to be targeted, but you want to return an UnexecutableCommand
to get the NOT sign..

> e.g. I would like to change the Circuit to allow user to drop a AND gate
> figure, but NOT a OR gate figure. It will show a Stop sign icon when I
> select a OR GATE figure and move it over to Circuit and when I move the
> cursor to a other container (e.g. Flow Container), it should a Drop icon
and
> I can add the OR gate to the Flow Container?
>
> Thanks
Previous Topic:How to Update GEF build
Next Topic:question on draw2d translateToAbsolute() and translateToRelative()
Goto Forum:
  


Current Time: Thu May 08 20:02:16 EDT 2025

Powered by FUDForum. Page generated in 0.02506 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top