在 e4 rcp 中切换处理程序的图像 [英] Switch Image of a Handler in a e4 rcp
本文介绍了在 e4 rcp 中切换处理程序的图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个 e4 rcp 应用程序,我想用一个工具栏项目扩展我的应用程序,当用户执行它时,它应该更改图标 URL.
I have an e4 rcp application and I want to extend my application with a toolbar item that should change the icon URL when the user execute it.
有没有可能像我在 MPart 中那样做到这一点?
Is there any possibility to do this as I can do it in a MPart?
推荐答案
只需在工具项的处理程序中调用 MToolItem
的 setIconURI
方法:
Just call the setIconURI
method of MToolItem
in your handler for the tool item:
@Execute
public void execute(MToolItem mitem)
{
mitem.setIconURI("platform:/plugin/......");
... other code
}
这篇关于在 e4 rcp 中切换处理程序的图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文