如何打开没有重复的零件?
How to open a Part without duplicate?
我正在开发 'Pure' Eclipse 4 RCP 应用程序。我想在 e3.x
中使用 page.openEditor(IEditorInput input, String editorId, boolean activate);
之类的方法打开 'part'
我该怎么做?
您使用EPartService
管理部件:
@Inject
private EPartService partService;
MPart mpart = partService.showPart("part id", PartState.ACTIVATE);
如有必要,您可以访问您的部分 class:
MyPart myPart = (MyPart)mpart.getObject();
我正在开发 'Pure' Eclipse 4 RCP 应用程序。我想在 e3.x
中使用page.openEditor(IEditorInput input, String editorId, boolean activate);
之类的方法打开 'part'
我该怎么做?
您使用EPartService
管理部件:
@Inject
private EPartService partService;
MPart mpart = partService.showPart("part id", PartState.ACTIVATE);
如有必要,您可以访问您的部分 class:
MyPart myPart = (MyPart)mpart.getObject();