To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=47888
------- Additional comments from [EMAIL PROTECTED] Mon Jul 18 18:44:24 -0700 2005 ------- pluby->jl I understand your desire to put this code in one of the jvm frameworks. However, I think that you misunderstand what the problem is. The problem is that with Apple's Java 1.4 or higher JVM, any AWT code will block forever if the primordial thread is not running a native event loop (i.e. CFRunLoopRun()) which means that such an event loop must be started in the primordial thread and before any AWT code is executed. If this native event loop is not started or is started in a non-primordial thread, the first AWT call will block. In other words, a native event loop absolutely must be run on the primordial thread for Java 1.4 and higher to work on Mac OS X. I consider this a major design flaw in Apple's JVM, but whether you load the JVM or use the JVM plugin, you will need this native event loop to be running on the primordial thread because this requirement exists with the AWT code itself. Why not run the native event loop on a different thread like other JVMs? Sorry, but I already tried it and it does not work. The reason is that Apple's JVM 1.4 and higher implementation executes all AWT calls within timers that the JVM posts explicitly to the primordial thread's native event queue. So, any native event loop started on a non-primordial thread will just sit idle and the timers on the primordial thread will never fire which will result in the same blocking behavior. The hanging that ericb is seeing occurs when one of the timers that the JVM posts has a wait condition to force the timer to run synchronously. In this case (which happens for a surprisingly large number of AWT calls), the SVMain() thread will block waiting for the timer posted to the primordial thread to fire. Given that this is a JVM restriction, the number of options are fairly limited. I think that implementing the native event loop creation and the move of Application::Main() to a non-primordial thread entirely within vcl makes the most sense since vcl is a location of platform dependent code and the location of my changes are in a position where Java is safe for OOo to load. --------------------------------------------------------------------- Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
