I am trying to create a tabbed property view in accordance with this article: View Eclipse tab properties
According to the article, the org.eclipse.ui.views.properties.tabbed.propertyTabs extension point can be used to add new tabs.
<extension point="org.eclipse.ui.views.properties.tabbed.propertyTabs"> <propertyTabs contributorId="mview.views.SampleView"> <propertyTab category="sample" id="mview.ButtonTab" label="Button"/> <propertyTab afterTab="mview.ButtonTab" category="sample" id="mview.AdvancedTab" label="Advanced"/> </propertyTabs> </extension>
However, in my case, the property tabs are displayed depending on the selected item. Therefore, I have to dynamically add tabs to the extension being added to the selected item.
Please suggest how to do this.
Update: One way to do this (I'm not sure I advised it) is using the IExtensionRegistry.addContribution () method. Here I presented an input stream object containing the required extension details. These are added tabs to the runtime view of properties. However, when you change the selection of an item in the list viewer, the property view is not updated. Please suggest if this is the right approach for this.
source share