Hi Roman,
the patch looks reasonable to me.
Thanks,
Dmitri
Roman Kennke wrote:
Hi there,
I've just synced up the Cacio forest with the JDK7 master forest, and
I'd like to discuss and try to merge back (into JDK7) some of our
patches. The following one affects all of AWT, Swing and J2D, this is
why I'm posting it to 3 lists at once.
In SwingUtilities2.isLocalDisplay(), we have some crazy platform
specific code to find if we have a local display or not. This is of
course not very nice for other Toolkit implementations than the Win32
and X11 ones in OpenJDK. Our solution is to introduce an abstract method
isLocalDisplay() in SunGraphicsEnvironment, which we call from
SwingUtilities2. This method is then overridden by the specific GE
implementations. If we don't have a SGE, we assume a local display.
There are also some changes in the native font code, which used to call
the static X11GraphicsEnvironment.isLocalDisplay(), to call the new
instance method in SGE.
What do you think? Is this reasonable to merge into mainline?
/Roman