aboutsummaryrefslogtreecommitdiffstats
path: root/src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java')
-rwxr-xr-xsrc/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java b/src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java
index 06ef8aacd..8983b8803 100755
--- a/src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java
+++ b/src/newt/classes/com/sun/javafx/newt/macosx/MacScreen.java
@@ -37,14 +37,20 @@ import com.sun.javafx.newt.*;
import javax.media.nativewindow.*;
public class MacScreen extends Screen {
+ static {
+ MacDisplay.initSingleton();
+ }
+
public MacScreen() {
- MacWindow.initSingleton();
}
protected void createNative(int index) {
aScreen = new DefaultGraphicsScreen(getDisplay().getGraphicsDevice(), index);
- setScreenSize(MacWindow.getScreenWidth(getIndex()), MacWindow.getScreenHeight(getIndex()));
+ setScreenSize(getWidthImpl(getIndex()), getHeightImpl(getIndex()));
}
protected void closeNative() { }
+
+ private static native int getWidthImpl(int scrn_idx);
+ private static native int getHeightImpl(int scrn_idx);
}