Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 345347

Summary: There should be a way to not allow other plugins to contribute to the diagram context menu
Product: [Modeling] Graphiti Reporter: Shenxue Zhou <shenxue.zhou>
Component: CoreAssignee: Project Inbox <graphiti-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: michael.wenz
Version: 0.8.0Flags: michael.wenz: indigo+
Target Milestone: 0.8.0   
Hardware: All   
OS: All   
Whiteboard: Indigo RC1 theme_bugs
Attachments:
Description Flags
Disallow context menu contributions from other plugins. michael.wenz: iplog+

Description Shenxue Zhou CLA 2011-05-10 19:06:27 EDT
Graphiti's diagram context menu contains menus contributed by other plugins such as "Run As", "Debug As", "Profile As", "Validate" etc. If I don't care those menus and want to have total control about what goes to the context menu, currently there is no way to do that. 

Graphiti could provide an easy way to allow subclasses of DiagramEditorInternal to do that. I'll provide a patch.
Comment 1 Shenxue Zhou CLA 2011-05-10 19:10:37 EDT
Created attachment 195284 [details]
Disallow context menu contributions from other plugins.
Comment 2 Michael Wenz CLA 2011-05-12 07:23:17 EDT
By default no of the entries you mentioned is entered into the context menu, but nevertheless you are right: tools should be able to prevent others from extending the context menu.

I have submitted your patch in head.

Just a remark: we want to clean-up the diagram editor API for the next release, so there might be some changes in the future to this as well. For details see https://bugs.eclipse.org/bugs/show_bug.cgi?id=336488

Michael
Comment 3 Michael Wenz CLA 2011-05-12 07:23:37 EDT
Comment on attachment 195284 [details]
Disallow context menu contributions from other plugins.

Marked as IPlog relevant
Comment 4 Michael Wenz CLA 2011-05-12 11:02:01 EDT
Verified in install
Comment 5 Michael Wenz CLA 2011-06-24 08:40:45 EDT
Part of Graphiti Indigo 0.8.0