Java 在eclipse应用程序中最小化简介部分
我在eclipse应用程序中创建了自己的简介,如下所示:Java 在eclipse应用程序中最小化简介部分,java,eclipse,eclipse-plugin,eclipse-rcp,Java,Eclipse,Eclipse Plugin,Eclipse Rcp,我在eclipse应用程序中创建了自己的简介,如下所示: public class CustomIntro extends IntroPart { public void createPartControl(Composite container) { //add intro, works perfectly fine } //override other essential methods } 上面的代码工作得非常好,现在我想通过编程最小化这个介绍。
public class CustomIntro extends IntroPart {
public void createPartControl(Composite container) {
//add intro, works perfectly fine
}
//override other essential methods
}
上面的代码工作得非常好,现在我想通过编程最小化这个介绍。点击按钮后,简介应最小化。实际上,我想在点击按钮后启动一个内部浏览器,并且应该最小化简介,并且启动的内部浏览器应该是可见的。
正如@greg-449所建议的,我扩展了IntroPart而不是实现IIntropart。谢谢你,但我的问题仍然存在。非常感谢您的帮助。如上所述,您应该扩展IntroPart
抽象类,如中所述。您可以使用setPartState()
在介绍部分中使用此选项:
this.getIntroSite().getPage().setPartState(this.getIntroSite().getPage().getActivePartReference(), IWorkbenchPage.STATE_MINIMIZED);
您应该扩展
org.eclipse.ui.part.IntroPart
,而不是自己实现所有接口方法<代码>IIntroPart标记为“不打算由客户实施”哦!我不知道。谢谢你。我做了改变。但你知道如何解决这个问题吗?