Adding a new context menu action to the data manager menu like this
<extension point="org.mitk.gui.qt.datamanager.contextMenuActions"> <contextMenuAction nodeDescriptorName="DescriptorName" label="DescriptorLabel"
icon="resources/DescriptorIcon.png" class="DescriptorClass" />
</extension>
does not set the icon.
The action itself is shown and works as expected. In QmitkDataManagerView::CreateQtPartControl(QWidget* parent) the context menu extension service is opened to read the descriptor name, label, class and icon attribute but is not using the icon to create the action:
...
if((*cmActionsIt)->GetAttribute("nodeDescriptorName", cmNodeDescriptorName)
&& (*cmActionsIt)->GetAttribute("label", cmLabel) && (*cmActionsIt)->GetAttribute("class", cmClass)) { (*cmActionsIt)->GetAttribute("icon", cmIcon); // create context menu entry here tmpDescriptor =
QmitkNodeDescriptorManager::GetInstance()->GetDescriptor(QString::fromStdString(cmNodeDescriptorName));
contextMenuAction = new QAction( QString::fromStdString(cmLabel),
parent);