Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Disable pop-up bars
Disable pop-up bars [message #550379] Fri, 30 July 2010 03:57 Go to next message
Eclipse UserFriend
Hello,

I would like to remove completely the "pop-up bar" feature (when hovering over the diagram or an element, a bar appears from which users can create new elements).
I thought this would be something not too difficult to do but I can't find an option in the generator model to turn off pop-up bars.

Thanks
Cédric

[Updated on: Fri, 30 July 2010 04:38] by Moderator

Re: Disable pop-up bars [message #550426 is a reply to message #550379] Fri, 30 July 2010 06:44 Go to previous messageGo to next message
Eclipse UserFriend
Hi Cédric,

currently I'm trying to implement exactly the opposite (popup bar on all elements Wink ).
While trying this I "accidentally" found a solution for your problem.

Take a look at the #createDefaultEditPolicies() Method of your root edit part (You did define it by creating your models - Graphical, Tooling, Mapping).

There's an commented line:
 // removeEditPolicy(org.eclipse.gmf.runtime.diagram.ui.editpolicies.EditPolicyRoles.POPUPBAR_ROLE);


All you need to do is to uncomment this line and add it to the #createDefaultEditPolicies() Method of every EditPart where you don't want the popup bar to appear.

Regards,
Kellogs
Re: Disable pop-up bars [message #550437 is a reply to message #550426] Fri, 30 July 2010 07:24 Go to previous messageGo to next message
Eclipse UserFriend
Hello,

Thanks a lot, that was exactly what I was looking for Razz .
Re: Disable pop-up bars [message #553574 is a reply to message #550426] Wed, 18 August 2010 01:22 Go to previous message
Eclipse UserFriend
Hi kellogs,

Did u succeed in put pop-up bars in all elements ? I am searching to do it too but cannot find the pop-up policies class to add it to my elements.

Thx

Fab
Previous Topic:copy paste not working with gmf 2.2
Next Topic:add an element that will be the same size as the editor one
Goto Forum:
  


Current Time: Tue Nov 04 08:39:14 EST 2025

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

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

Back to the top