|Adding custom view to the Common Navigator [message #558913]
||Tue, 14 September 2010 20:37
| Xavier Coulon
Registered: July 2009
I'm developping a custom view based on the Common Navigator Framework to display the a specific metamodel of a selected project.
When a user selects a resource in a project or a project, a builder 'builds' the metamodel and the content is displayed in the viewer.
Now, I'd like to add the following custom behaviour : when the facet is not installed on the selected project (or resource's project), the viewer would display a text with a link that would automatically open the project's property page.
From the extension point definition, I can see that some contentProvider enablement is possible with an assertion on whether the facet is installed or not. So, I could create a special 'contentProvider' in of a project on which my facet is not installed, but it seems rather weird, as this contentProvider would be selectable in the "Customize view" menu (unless it can be programmatically disabled), and still, it does not solve the second part of the behavious, ie, providing a 'link' in the text. Using a LabelProvider with implements IStyledLabelProvider wouldn't allow me to provide link, would it ?
So, is there any clean way to implement this feature ?
Thank you in advance.
Powered by FUDForum
. Page generated in 0.01900 seconds