On 12/07/2012 6:58 PM, Leonid Romanov wrote:
Perhaps Anthony might be able to answer your question: he has tinkered a lot 
with headless related stuff.
David, are you implying that in the current form my fix is no-go?

Not my place to do that. I'm just wondering how the HToolkit got involved with OSX, and why OSX headless is handled differently to Solaris/linux (which don't use HToolkit).

David

On 12.07.2012, at 5:15, David Holmes wrote:

On 11/07/2012 11:46 PM, Leonid Romanov wrote:
Hi,
Please review a fix for 7181027: [macosx] Unable to use headless mode. The problem here 
is that for headless mode  "java.awt.graphicsenv" system property should be 
CGraphicsEnvironment because the way GraphicsEnvironment.createGE() method works: it 
first instantiates GraphicsEnvironment instance and then wraps it with 
HeadlessGraphicsEnvironment if in headless mode. This means twe can't use 
java.awt.graphicsenv property to determine whether we are in headless mode or not. So, 
I've replaced it with a toolkit check: if it's HToolkit, then we are in headless.

sun.awt.HToolkit was introduced for use by SE-Embedded's reduced headless JRE. 
How did the OSX port end up using it ???

Headless handling on OSX should be like regular headless on Linux, Solaris.

David

Bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7181027
Webrev: http://cr.openjdk.java.net/~leonidr/7181027/webrev.00/

Thanks,
Leonid.


Reply via email to