title: Non-headless mode: Apple AWT Java VM was loaded on first thread
body: <p>I'm developing a maven-built JavaFX 2 application in eclipse.</p>
  
  <p>Everything is running fine on Windows, but Mac OSX is causing problems. I have to include the following line to prevent the application from starting in Headless mode:</p>
  
  <pre><code>System.setProperty("java.awt.headless", "false");
  </code></pre>
  
  <p>However, disabling headless mode like that is giving me this error on Mac:</p>
  
  <blockquote>
    <p>java[15689:707] Cocoa AWT: Apple AWT Java VM
    was loaded on first thread -- can't start AWT. (  </p>
    
    <p>0   liblwawt.dylib<br>
    0x000000016674fba2 JNI_OnLoad + 468   1   libjava.dylib<br>
    0x00000001037286d1 Java_java_lang_ClassLoader_00024NativeLibrary_load
    + 207     2   ???                                 0x00000001037fef90 0x0 + 4353683344 ) Exception in Application start method</p>
  </blockquote>
  
  <p>There are no problems running in headless mode but I need the Robot class to handle keyPress events. I don't even know why it's trying to run headless while I don't need it.</p>