jdk/src/share/classes/java/awt/GraphicsEnvironment.java
changeset 2372 229b2c88d29c
parent 2 90ce3da70b43
child 3016 2b51287517f1
--- a/jdk/src/share/classes/java/awt/GraphicsEnvironment.java	Wed Dec 24 09:53:52 2008 -0800
+++ b/jdk/src/share/classes/java/awt/GraphicsEnvironment.java	Wed Dec 24 09:57:48 2008 -0800
@@ -356,6 +356,9 @@
      * @since 1.5
      */
     public void preferLocaleFonts() {
+        if (!(this instanceof SunGraphicsEnvironment)) {
+            return;
+        }
         sun.font.FontManager.preferLocaleFonts();
     }
 
@@ -376,6 +379,9 @@
      * @since 1.5
      */
     public void preferProportionalFonts() {
+        if (!(this instanceof SunGraphicsEnvironment)) {
+            return;
+        }
         sun.font.FontManager.preferProportionalFonts();
     }