summaryrefslogtreecommitdiffstats
path: root/src/newt/classes/jogamp
diff options
context:
space:
mode:
authorSven Gothel <sgothel@jausoft.com>2012-05-02 01:20:46 +0200
committerSven Gothel <sgothel@jausoft.com>2012-05-02 01:20:46 +0200
commit935523a8c58efced1c0845bd60e08e2acb9e5aee (patch)
tree3719897e3c2804abff130e299858df7c09f84588 /src/newt/classes/jogamp
parent969567663c08597c2c2effe6128f4810ec252513 (diff)
NEWT API Change 'WindowClosingProtocol': Use 'enum WindowClosingMode' instead of static final int values.
Diffstat (limited to 'src/newt/classes/jogamp')
-rw-r--r--src/newt/classes/jogamp/newt/WindowImpl.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/newt/classes/jogamp/newt/WindowImpl.java b/src/newt/classes/jogamp/newt/WindowImpl.java
index b3a3e54ec..143e7c1ed 100644
--- a/src/newt/classes/jogamp/newt/WindowImpl.java
+++ b/src/newt/classes/jogamp/newt/WindowImpl.java
@@ -385,17 +385,17 @@ public abstract class WindowImpl implements Window, NEWTEventConsumer
// WindowClosingProtocol implementation
//
private Object closingListenerLock = new Object();
- private int defaultCloseOperation = DISPOSE_ON_CLOSE;
+ private WindowClosingMode defaultCloseOperation = WindowClosingMode.DISPOSE_ON_CLOSE;
- public int getDefaultCloseOperation() {
+ public WindowClosingMode getDefaultCloseOperation() {
synchronized (closingListenerLock) {
return defaultCloseOperation;
}
}
- public int setDefaultCloseOperation(int op) {
+ public WindowClosingMode setDefaultCloseOperation(WindowClosingMode op) {
synchronized (closingListenerLock) {
- int _op = defaultCloseOperation;
+ WindowClosingMode _op = defaultCloseOperation;
defaultCloseOperation = op;
return _op;
}
@@ -2476,7 +2476,7 @@ public abstract class WindowImpl implements Window, NEWTEventConsumer
/**
* Triggered by implementation's WM events or programmatically
*
- * @param force if true, overrides {@link #setDefaultCloseOperation(int)} with {@link WindowClosingProtocol#DISPOSE_ON_CLOSE}
+ * @param force if true, overrides {@link #setDefaultCloseOperation(WindowClosingMode)} with {@link WindowClosingProtocol#DISPOSE_ON_CLOSE}
* and hence force destruction. Otherwise is follows the user settings.
* @return true if this window is no more valid and hence has been destroyed, otherwise false.
*/
@@ -2485,13 +2485,13 @@ public abstract class WindowImpl implements Window, NEWTEventConsumer
System.err.println("Window.windowDestroyNotify(force: "+force+") START "+getThreadName()+": "+this);
}
if(force) {
- setDefaultCloseOperation(WindowClosingProtocol.DISPOSE_ON_CLOSE);
+ setDefaultCloseOperation(WindowClosingMode.DISPOSE_ON_CLOSE);
}
// send synced destroy notifications
enqueueWindowEvent(true, WindowEvent.EVENT_WINDOW_DESTROY_NOTIFY);
- if(handleDestroyNotify && DISPOSE_ON_CLOSE == getDefaultCloseOperation()) {
+ if(handleDestroyNotify && WindowClosingMode.DISPOSE_ON_CLOSE == getDefaultCloseOperation()) {
destroy();
}