Fixes for Java 1.5 version of java.awt.