Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BPMN Modeler » Add item in context menu
Add item in context menu [message #12668] Thu, 04 June 2009 15:06 Go to next message
mio is currently offline mioFriend
Messages: 4
Registered: July 2009
Junior Member
hi
a question: it's possible to add an item in the context menu when there is
a right click over a pool ?
what is the best way (if it's possible) ?
best regards
Re: Add item in context menu [message #12709 is a reply to message #12668] Fri, 05 June 2009 09:04 Go to previous message
Eclipse UserFriend
Originally posted by: atoulme.intalio.com

mio wrote:
> hi
> a question: it's possible to add an item in the context menu when there
> is a right click over a pool ?
> what is the best way (if it's possible) ?
> best regards
>
Sure, it's part of the GMF standard extensions.

You will need to plug your own
org.eclipse.gmf.runtime.common.ui.services.action.contributi onItemProviders
extension point and provide a new popupContribution, like this one:

<popupContribution

class=" org.eclipse.gmf.runtime.diagram.ui.providers.DiagramContextM enuProvider ">
<popupStructuredContributionCriteria

objectClass=" org.eclipse.stp.bpmn.diagram.edit.parts.SequenceEdgeEditPart "
objectCount="1">
</popupStructuredContributionCriteria>
<popupMenu
id="conditionType"
path="/additionsGroup">
</popupMenu>
<popupMenuGroup
id="group1"
path="/conditionType/"
separator="true">
</popupMenuGroup>
<popupAction
id="conditionTypeNone"
path="/conditionType/group1">
</popupAction>
</popupContribution>

You will need to implement your own action provider, extending
AbstractContributionItemProvider and bind to the extension point as well.

I am sure the GMF developers have that documented somewhere in a more
complete way.

Thanks,

Antoine
Previous Topic:Cannot open Europa based models in Ganymede Modeller
Next Topic:Re: Traverse a BPMN diagram
Goto Forum:
  


Current Time: Tue Mar 19 10:50:51 GMT 2024

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

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

Back to the top