It's all about the answers!

Ask a question

Overriding "Submit for review" action


Piotr Godowski (611) | asked Jun 10 '09, 10:52 a.m.
Hello guys,

I am trying to tweak a bit the "Submit for Review" action that is available when one associated work item with the change set being delivered.

What I see, the submit for review popup menu entry is declared in the com.ibm.team.filesystem.rcp.ui.workitems plugin and is declared as the viewer contribution action, hook into the view
com.ibm.team.filesystem.rcp.core.internal.changes.model.IOutgoingRemoteActivity

and the action id is
com.ibm.team.filesystem.ui.changes.actions.quick.SubmitForReviewAction


So, I created a plugin that uses extension point
org.eclipse.ui.popupMenus
and tries to override action using the attribute
overrideActionId
(see http://help.eclipse.org/help32/topic/org.eclipse.platform.doc.isv/reference/extension-points/org_eclipse_ui_popupMenus.html#e.action).

And what is happening is that that action is cannot be resolved at the compile time and Eclipse is marking that overrideActionId with a warning:
Referenced identifier 'com.ibm.team.filesystem.ui.changes.actions.quick.SubmitForReviewAction' in attribute 'overrideActionId' cannot be found	plugin.xml

Also, when I deployed that plugin into RTC, the "Submit for review" action
is not overriden, my new action is shown and works fine, but does not override the intended action at all.

Any ideas what may I be doing wrong? Really appreciate your help guys.

Thanks,
Piotr.

2 answers



permanent link
Andrew Hoo (1.0k1) | answered Jun 10 '09, 11:47 a.m.
JAZZ DEVELOPER
I haven't tried testing this myself but the PopupMenu extension doc you gave says:

overrideActionId - an optional attribute that specifies the identifier of an action which this action overrides. The action represented by this identifier will not be contributed to the context menu. The action identifier must be from a prerequisite plug-in only. This attribute is only applicable to action elements of an object contribution.


So, I'm not sure if it means that your contribution must be an object contribution or if it means that the SubmitForReviewAction must be an object contribution (which you've identified as being a viewer contribution). And then, I'm not sure if it will work having an object contribution overriding a viewer contribution.

The only other part that catches my eye is listing the com.ibm.team.filesystem.rcp.ui.workitems plugin as a prerequisite; which could be the warning about not being able to find the id reference.

permanent link
Piotr Godowski (611) | answered Jun 10 '09, 4:49 p.m.
I haven't tried testing this myself but the PopupMenu extension doc you gave says

Yes, that is true - I am trying to override the viewer contribution and it does not seem to work. Any idea whether is there any other way should I follow then? From the RTC point of view.. or maybe should I just try somehow to manually manipulate the actions of the popup menu to achieve customizability?


The only other part that catches my eye is listing the com.ibm.team.filesystem.rcp.ui.workitems plugin as a prerequisite; which could be the warning about not being able to find the id reference.

That is true - one has to specify the target plugin as a prerequisite, which I did but apparently is not working anyway.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.