src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java

Print this page

        

*** 75,86 **** --- 75,95 ---- } }); if (!GraphicsEnvironment.isHeadless()) { initIDs(); } + inAWT = AccessController.doPrivileged(new PrivilegedAction<Boolean>() { + @Override + public Boolean run() { + return !Boolean.parseBoolean(System.getProperty("javafx.embed.singleThread", "false")); + } + }); } + /* If we operate in FX/AWT single threaded mode the nested loop should run in default mode */ + private static final boolean inAWT; + public LWCToolkit() { SunToolkit.setDataTransfererClassName("sun.lwawt.macosx.CDataTransferer"); areExtraMouseButtonsEnabled = Boolean.parseBoolean(System.getProperty("sun.awt.enableExtraMouseButtons", "true")); //set system property if not yet assigned
*** 699,709 **** * processing which could break Appkit. * (One known example is when the window is resized with the mouse) * * if false - all events come after exit form the nested loop */ ! static native void doAWTRunLoop(long mediator, boolean processEvents); static native void stopAWTRunLoop(long mediator); private native boolean nativeSyncQueue(long timeout); @Override --- 708,721 ---- * processing which could break Appkit. * (One known example is when the window is resized with the mouse) * * if false - all events come after exit form the nested loop */ ! static void doAWTRunLoop(long mediator, boolean processEvents) { ! doAWTRunLoopImpl(mediator, processEvents, inAWT); ! } ! static private native void doAWTRunLoopImpl(long mediator, boolean processEvents, boolean inAWT); static native void stopAWTRunLoop(long mediator); private native boolean nativeSyncQueue(long timeout); @Override