[solved] popupMenus on IMarker [message #696270] |
Wed, 13 July 2011 11:41  |
Eclipse User |
|
|
|
Hi everyone,
I have an issue with a plugin i wrote a while ago (Eclipse 3.2 times I think) which does not work as I would expect anymore. It did in the past with the same code.
I create some IMarkers and would like to have a menu item in the popupMenu.
This is what I use as extension point:
<extension
point="org.eclipse.ui.popupMenus">
<objectContribution
id="de.test.consoleparser.objectContribution1"
objectClass="org.eclipse.core.resources.IMarker">
<action
class="de.test.consoleparser.ui.DeleteMarkerDelegate"
id="de.test.consoleparser.ui.DeleteMarker"
label="Delete Marker"
menubarPath="additions">
</action>
</objectContribution>
</extension>
The menu item just doesn't appear. The funny thing is that when changing the object class to use IFile as in the following line, the menu item appears (in the file context menu).
objectClass="org.eclipse.core.resources.IFile"
So I guess generally what I am doing seems to be not completely wrong, but something is not working the way think it is. As mentioned it did work previously.
Any suggestions or hints?
Thanks in advance!
[Updated on: Wed, 20 July 2011 09:06] by Moderator
|
|
|
|
|
|
|
Re: popupMenus on IMarker [message #698917 is a reply to message #698909] |
Wed, 20 July 2011 09:24  |
Eclipse User |
|
|
|
Christian Opitz wrote on Wed, 20 July 2011 08:58
No idea if the flag is new, the default value has changed or it just accidentally worked in the past, but the new version looks like this:
The flag is old (often used because java projects are IJavaProjects, not IProjects, but many objectContributions care about IProjects) but all of the Markers views were re-implemented between 3.2 and now. So now (apparently) you need to adapt to see IMarker (in the previous implementation the view model objects must have implemented IMarker directly, but the no longer do so).
PW
|
|
|
Powered by
FUDForum. Page generated in 0.03605 seconds