Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Remove menu for creating child nodes in the parent node
Remove menu for creating child nodes in the parent node [message #692816] Tue, 05 July 2011 05:53 Go to next message
Eclipse UserFriend
Hi,

I have a parent node, with two child nodes affixed to its east and west sides. These child nodes are created programatically. In order to avoid creating them by means of a tool, I didn't add a creation tool in the palette, but when I pass the mouse over the parent node, a context menu appear with the options for creating these child nodes. How can I avoid this context menu?


Thanks in advance,

Aintzane
Re: Remove menu for creating child nodes in the parent node [message #693000 is a reply to message #692816] Tue, 05 July 2011 11:49 Go to previous message
Eclipse UserFriend
Hi Aintzane,

in your [XYZ]DiagramEditPart.createDefaultEditPolicies() you have to add the following code:

[...]
removeEditPolicy(EditPolicyRoles.POPUPBAR_ROLE);
removeEditPolicy(EditPolicyRoles.CONNECTION_HANDLES_ROLE);


HTH, bye

Giovanni

Previous Topic:Register the diagram as selection provider
Next Topic:Get All the Information in the Diagram
Goto Forum:
  


Current Time: Sat Jul 05 00:43:58 EDT 2025

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

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

Back to the top