Re: sun/awt/OSInfo.java

2013-06-24 Thread Alan Bateman
On 24/06/2013 09:23, Weijun Wang wrote: I don't meant to add any API for external users, but even JDK itself needs some helper classes, and looks like sun.misc is the place. In this case, there are too many places inside JDK that checks what the current OS is. Some uses startsWith and some con

Re: sun/awt/OSInfo.java

2013-06-24 Thread Weijun Wang
' but it's actually 'SunOS'. There is a helper class at http://hg.openjdk.java.net/jdk8/tl/jdk/file/fd050ba1cf72/src/share/classes/sun/awt/OSInfo.java This file uses if (osName.contains("Solaris") || osName.contains("SunOS")) Is it real that the value can b

Re: sun/awt/OSInfo.java

2013-06-24 Thread Alan Bateman
On 24/06/2013 05:57, Weijun Wang wrote: I thought os.name for Solaris is 'Solaris' but it's actually 'SunOS'. There is a helper class at http://hg.openjdk.java.net/jdk8/tl/jdk/file/fd050ba1cf72/src/share/classes/sun/awt/OSInfo.java This file uses if

sun/awt/OSInfo.java

2013-06-23 Thread Weijun Wang
I thought os.name for Solaris is 'Solaris' but it's actually 'SunOS'. There is a helper class at http://hg.openjdk.java.net/jdk8/tl/jdk/file/fd050ba1cf72/src/share/classes/sun/awt/OSInfo.java This file uses if (osName.contains("Solaris") || osName.cont