rashmi
rashmi

Reputation: 203

Adding user defined menu to Enterprise Architect element

I am working on Enterprise Architect c# add-ins and I need to display a user-defined context Menu when any element is right-clicked in diagram workspace or Project Browser instead of the default Menu.

There are context Item events available for contextItemClicked,contextItemDoubleClicked etc. Is there any add-in event available for the right-click of an element.

Kindly Help. Thanks in advance.

Upvotes: 1

Views: 181

Answers (2)

Geert Bellekens
Geert Bellekens

Reputation: 13784

EA_GetmenuItems has some parameters to control the context menu depending on the selected element, and you can still Repository.GetContextObject() or Repository.GetContextItemType() to refine it even more.

Upvotes: 1

qwerty_so
qwerty_so

Reputation: 36313

I guess that EA_OnContextItemChanged will do the trick.

Upvotes: 1

Related Questions