Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Create automatically link between nodes
icon5.gif  Create automatically link between nodes [message #499882] Tue, 24 November 2009 13:17 Go to next message
st oehm is currently offline st oehmFriend
Messages: 79
Registered: October 2009
Member
Hi,

following situation: I have a context menu for my diagram where I select an already existing instance of node type A and when the 'OK' button is pressed an instance of node type B is automatically created.

Now, I would like to have a line be drawn automatically between instance of type A and the newly created instance of type B.

GMF offers those so called design links. I have already tried to create a design link between the two nodes, but it didn't work since I couldn't select a source/target for the link.

Now my question is how to create a design link automatically between the two nodes via context menu? Or does anybody have a better idea to get a similar solution?

Thanks in advance and best regards,
stoehm
Re: Create automatically link between nodes [message #499955 is a reply to message #499882] Tue, 24 November 2009 15:13 Go to previous message
Artur Kronenberg is currently offline Artur KronenbergFriend
Messages: 159
Registered: August 2009
Senior Member
Hi Stoem,

did you look into the CreateRelationShipCommand and CreateRelationshipRequest classes? It seems to me that thoses are the classes that are responsible for creating your line.

Best regards,
Artur

stoehm wrote on Tue, 24 November 2009 08:17
Hi,

following situation: I have a context menu for my diagram where I select an already existing instance of node type A and when the 'OK' button is pressed an instance of node type B is automatically created.

Now, I would like to have a line be drawn automatically between instance of type A and the newly created instance of type B.

GMF offers those so called design links. I have already tried to create a design link between the two nodes, but it didn't work since I couldn't select a source/target for the link.

Now my question is how to create a design link automatically between the two nodes via context menu? Or does anybody have a better idea to get a similar solution?

Thanks in advance and best regards,
stoehm

Previous Topic:display connection in outline view
Next Topic:Ctrl + Click afor editpart Selection and performing some action
Goto Forum:
  


Current Time: Tue Apr 23 06:56:23 GMT 2024

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

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

Back to the top