aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes/com/sun/javafx/newt/x11/X11Window.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2008-11-27 03:27:17 +0000
committerSven Gothel <[email protected]>2008-11-27 03:27:17 +0000
commit62daa94704f3f5125916b81a3494d45ab0c0d09a (patch)
tree4292296ffb209dd616788eeb5bdc5c5ebe0e557e /src/classes/com/sun/javafx/newt/x11/X11Window.java
parent47c0b60fa9fdd1df48cad1ec999ba40c3185e28f (diff)
Newt-KD: working inc. events. Screen size can be set w/ property newt.ws.swidth newt.ws.sheight
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1807 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/javafx/newt/x11/X11Window.java')
-rwxr-xr-xsrc/classes/com/sun/javafx/newt/x11/X11Window.java16
1 files changed, 3 insertions, 13 deletions
diff --git a/src/classes/com/sun/javafx/newt/x11/X11Window.java b/src/classes/com/sun/javafx/newt/x11/X11Window.java
index 311ba7dae..c77933f18 100755
--- a/src/classes/com/sun/javafx/newt/x11/X11Window.java
+++ b/src/classes/com/sun/javafx/newt/x11/X11Window.java
@@ -95,10 +95,10 @@ public class X11Window extends Window {
if(this.fullscreen!=fullscreen) {
int x,y,w,h;
this.fullscreen=fullscreen;
- if(this.fullscreen) {
+ if(fullscreen) {
x = 0; y = 0;
- w = getDisplayWidth0(getDisplayHandle(), getScreenIndex())/2;
- h = getDisplayHeight0(getDisplayHandle(), getScreenIndex())/2;
+ w = screen.getWidth();
+ h = screen.getHeight();
} else {
x = nfs_x;
y = nfs_y;
@@ -111,14 +111,6 @@ public class X11Window extends Window {
return true;
}
- public int getDisplayWidth() {
- return getDisplayWidth0(getDisplayHandle(), getScreenIndex());
- }
-
- public int getDisplayHeight() {
- return getDisplayHeight0(getDisplayHandle(), getScreenIndex());
- }
-
protected void dispatchMessages(int eventMask) {
DispatchMessages(getDisplayHandle(), windowHandle, eventMask);
}
@@ -135,8 +127,6 @@ public class X11Window extends Window {
private native void DispatchMessages(long display, long windowHandle, int eventMask);
private native void setSize0(long display, long windowHandle, int width, int height, int decorationToggle, boolean isVisible);
private native void setPosition0(long display, long windowHandle, int x, int y);
- private native int getDisplayWidth0(long display, int scrn_idx);
- private native int getDisplayHeight0(long display, int scrn_idx);
private void sizeChanged(int newWidth, int newHeight) {
width = newWidth;