作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我有自己的 IApplication
并将 start()
修改为:
@Override
public Object start( IApplicationContext context )
{
LOGGER.debug( "Application.start(IApplicationContext context " + context + ")" );
Display display = PlatformUI.createDisplay();
try
{
int returnCode = PlatformUI.createAndRunWorkbench( display, new ApplicationWorkbenchAdvisor() );
if (returnCode == PlatformUI.RETURN_RESTART)
{
return IApplication.EXIT_RESTART;
}
return IApplication.EXIT_OK;
}
finally
{
display.dispose();
}
}
然后我在我的处理程序之一中为我的按钮之一调用 PlatformUI.getWorkbench().restart();
。当我在 Eclipse 中运行时它工作正常,但当我构建为 java webstart 时应用程序只是关闭。
我读了这个link据我了解,如果它不是由 eclipse.exe 启动的,它将无法运行。但是,我还没有找到它的最终解决方案。有什么想法吗?
最佳答案
来自 Eclipse help关于使用 Java Web Start:
Known limitations
Request to exit the application with a restart code are ignored;
所以目前这是不可能的。
关于java - RCP 应用程序未重新启动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37653464/
我是一名优秀的程序员,十分优秀!