diff options
Diffstat (limited to 'src/newt/classes/com')
-rw-r--r-- | src/newt/classes/com/jogamp/newt/Display.java | 2 | ||||
-rw-r--r-- | src/newt/classes/com/jogamp/newt/NewtFactory.java | 17 |
2 files changed, 7 insertions, 12 deletions
diff --git a/src/newt/classes/com/jogamp/newt/Display.java b/src/newt/classes/com/jogamp/newt/Display.java index a0a098481..4469189a8 100644 --- a/src/newt/classes/com/jogamp/newt/Display.java +++ b/src/newt/classes/com/jogamp/newt/Display.java @@ -222,7 +222,7 @@ public abstract class Display { synchronized(displayList) { int i = fromIndex >= 0 ? fromIndex : displayList.size() - 1 ; while( ( incr > 0 ) ? i < displayList.size() : i >= 0 ) { - final Display display = (Display) displayList.get(i).get(); + final Display display = displayList.get(i).get(); if( null == display ) { // Clear GC'ed dead reference entry! displayList.remove(i); diff --git a/src/newt/classes/com/jogamp/newt/NewtFactory.java b/src/newt/classes/com/jogamp/newt/NewtFactory.java index 5ae3f3692..157e2bb3c 100644 --- a/src/newt/classes/com/jogamp/newt/NewtFactory.java +++ b/src/newt/classes/com/jogamp/newt/NewtFactory.java @@ -59,11 +59,6 @@ public class NewtFactory { @Override public Object run() { NativeWindowFactory.initSingleton(); // last resort .. - - // Work-around for initialization order problems on Mac OS X - // between native Newt and (apparently) Fmod - WindowImpl.init(NativeWindowFactory.getNativeWindowType(true)); - return null; } } ); } @@ -320,9 +315,9 @@ public class NewtFactory { public static boolean isScreenCompatible(NativeWindow parent, Screen childScreen) { // Get parent's NativeWindow details - AbstractGraphicsConfiguration parentConfig = (AbstractGraphicsConfiguration) parent.getGraphicsConfiguration(); - AbstractGraphicsScreen parentScreen = (AbstractGraphicsScreen) parentConfig.getScreen(); - AbstractGraphicsDevice parentDevice = (AbstractGraphicsDevice) parentScreen.getDevice(); + AbstractGraphicsConfiguration parentConfig = parent.getGraphicsConfiguration(); + AbstractGraphicsScreen parentScreen = parentConfig.getScreen(); + AbstractGraphicsDevice parentDevice = parentScreen.getDevice(); DisplayImpl childDisplay = (DisplayImpl) childScreen.getDisplay(); String parentDisplayName = childDisplay.validateDisplayName(null, parentDevice.getHandle()); @@ -343,9 +338,9 @@ public class NewtFactory { public static Screen createCompatibleScreen(NativeWindow parent, Screen childScreen) { // Get parent's NativeWindow details - AbstractGraphicsConfiguration parentConfig = (AbstractGraphicsConfiguration) parent.getGraphicsConfiguration(); - AbstractGraphicsScreen parentScreen = (AbstractGraphicsScreen) parentConfig.getScreen(); - AbstractGraphicsDevice parentDevice = (AbstractGraphicsDevice) parentScreen.getDevice(); + AbstractGraphicsConfiguration parentConfig = parent.getGraphicsConfiguration(); + AbstractGraphicsScreen parentScreen = parentConfig.getScreen(); + AbstractGraphicsDevice parentDevice = parentScreen.getDevice(); if(null != childScreen) { // check if child Display/Screen is compatible already |