IDEA-101990 workaround. JDK Application class is used instead of  custom native method invocation. Prevents crashes with JDK7  because of non-AppKit thread invocations.