Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » Create object on dropping connection to diagram
Create object on dropping connection to diagram [message #648722] Fri, 14 January 2011 09:18 Go to next message
Markus Muenkel is currently offline Markus Muenkel
Messages: 2
Registered: January 2011
Location: Walldorf, Germany
Junior Member
Hello,

the tutorial contains a section about creating connections with drag & drop from anchors. It is mentioned that if several create connection features are exposed as drag and drop features, the user is presented a choice of applicable features on drop.

There is a similar use case where the user drops the connection to the diagram and is presented a choice of possible objects to create. When an object is picked, a new object is created plus the connection is created and connected to the anchor of the new object.

What would be the recommended implementation of this use case? Should I use custom features?

Thanks in advance!
Markus
Re: Create object on dropping connection to diagram [message #649007 is a reply to message #648722] Mon, 17 January 2011 08:16 Go to previous message
Michael Wenz is currently offline Michael Wenz
Messages: 1595
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Markus,

for the first use case you should use CreateConnectionFeatures and add all
possibilities to one create new connection entry (class
ConnectionCreationToolEntry) in the palette. I haven't tried the second
thing, but that will probable work just the same way.

The general recommendation would be to use the most specific feature type
possible.

Michael


"Markus Muenkel" <ultra_nebula@yahoo.de> wrote in message
news:igp42f$h5$1@news.eclipse.org...
> Hello,
>
> the tutorial contains a section about creating connections with drag &
> drop from anchors. It is mentioned that if several create connection
> features are exposed as drag and drop features, the user is presented a
> choice of applicable features on drop.
>
> There is a similar use case where the user drops the connection to the
> diagram and is presented a choice of possible objects to create. When an
> object is picked, a new object is created plus the connection is created
> and connected to the anchor of the new object.
>
> What would be the recommended implementation of this use case? Should I
> use custom features?
>
> Thanks in advance!
> Markus
Previous Topic:Unregistering images when closing the diagram editor
Next Topic:Graphiti service release 0.7.1 is available for download
Goto Forum:
  


Current Time: Sat Sep 20 02:05:10 GMT 2014

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

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