|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
public interface WindowConstants
用於控制視窗關閉操作的常數。由 JFrame、JInternalFrame 和 JDialog 提供的 setDefaultCloseOperation 和 getDefaultCloseOperation 方法使用這些常數。有關設置預設視窗操作的範例,請參閱 The Java Tutorial 中的 Responding to Window-Closing Events 一節。
JFrame.setDefaultCloseOperation(int),
JDialog.setDefaultCloseOperation(int),
JInternalFrame.setDefaultCloseOperation(int)| 欄位摘要 | |
|---|---|
static int |
DISPOSE_ON_CLOSE
移除視窗的預設視窗關閉操作。 |
static int |
DO_NOTHING_ON_CLOSE
無操作預設視窗關閉操作。 |
static int |
EXIT_ON_CLOSE
退出應用程序預設視窗關閉操作。 |
static int |
HIDE_ON_CLOSE
隱藏視窗的預設視窗關閉操作 |
| 欄位詳細資訊 |
|---|
static final int DO_NOTHING_ON_CLOSE
static final int HIDE_ON_CLOSE
static final int DISPOSE_ON_CLOSE
註:當 Java 虛擬機器 (VM) 中最後的可顯示視窗被移除後,虛擬機器可能會終止。有關更多資訊,請參閱 AWT Threading Issues。
Window.dispose(),
JInternalFrame.dispose(),
常數欄位值static final int EXIT_ON_CLOSE
JFrame)可能會根據 SecurityManager 拋出一個 SecurityException。建議您只在應用程序中使用此項操作。
JFrame.setDefaultCloseOperation(int),
常數欄位值
|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
版權所有 2008 Sun Microsystems, Inc. 保留所有權利。請遵守GNU General Public License, version 2 only。