本文整理了Java中org.eclipse.jface.window.Window.setReturnCode()
方法的一些代码示例,展示了Window.setReturnCode()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Window.setReturnCode()
方法的具体详情如下:
包路径:org.eclipse.jface.window.Window
类名称:Window
方法名:setReturnCode
[英]Sets this window's return code. The return code is automatically returned by open
if block on open is enabled. For non-blocking opens, the return code needs to be retrieved manually using getReturnCode
.
[中]设置此窗口的返回代码。如果启用了“打开时阻塞”,返回代码将由open
自动返回。对于非阻塞打开,需要使用getReturnCode
手动检索返回代码。
代码示例来源:origin: org.eclipse.rap/org.eclipse.rap.jface
/**
* Notifies that the window's close button was pressed, the close menu was
* selected, or the ESCAPE key pressed.
* <p>
* The default implementation of this framework method sets the window's
* return code to <code>CANCEL</code> and closes the window using
* <code>close</code>. Subclasses may extend or reimplement.
* </p>
*/
protected void handleShellCloseEvent() {
setReturnCode(CANCEL);
close();
}
代码示例来源:origin: org.eclipse.platform/org.eclipse.jface
/**
* Notifies that the window's close button was pressed, the close menu was
* selected, or the ESCAPE key pressed.
* <p>
* The default implementation of this framework method sets the window's
* return code to <code>CANCEL</code> and closes the window using
* <code>close</code>. Subclasses may extend or reimplement.
* </p>
*/
protected void handleShellCloseEvent() {
setReturnCode(CANCEL);
close();
}
代码示例来源:origin: org.eclipse.scout.sdk.deps/org.eclipse.jface
/**
* Notifies that the window's close button was pressed, the close menu was
* selected, or the ESCAPE key pressed.
* <p>
* The default implementation of this framework method sets the window's
* return code to <code>CANCEL</code> and closes the window using
* <code>close</code>. Subclasses may extend or reimplement.
* </p>
*/
protected void handleShellCloseEvent() {
setReturnCode(CANCEL);
close();
}
内容来源于网络,如有侵权,请联系作者删除!