8160879: [PIT] CloseOnMouseClickPropertyTest fails with AA hint:Nonantialiased rendering mode exception
authoralexsch
Thu, 07 Jul 2016 15:39:19 +0300
changeset 39841 a733f9d32e66
parent 39840 85dfe553dd9c
child 39842 459c9c8a5a68
8160879: [PIT] CloseOnMouseClickPropertyTest fails with AA hint:Nonantialiased rendering mode exception Reviewed-by: ssadetsky, azvegint
jdk/src/java.desktop/share/classes/sun/swing/SwingUtilities2.java
jdk/test/javax/swing/JMenuItem/8158566/CloseOnMouseClickPropertyTest.java
--- a/jdk/src/java.desktop/share/classes/sun/swing/SwingUtilities2.java	Thu Jul 07 16:47:37 2016 +0530
+++ b/jdk/src/java.desktop/share/classes/sun/swing/SwingUtilities2.java	Thu Jul 07 15:39:19 2016 +0300
@@ -1093,7 +1093,7 @@
 
         FontRenderContext frc = cache.get(key);
         if (frc == null) {
-            aaHint = (aaHint == null) ? VALUE_ANTIALIAS_OFF : aaHint;
+            aaHint = (aaHint == null) ? VALUE_TEXT_ANTIALIAS_OFF : aaHint;
             frc = new FontRenderContext(tx, aaHint,
                                         VALUE_FRACTIONALMETRICS_DEFAULT);
             cache.put(key, frc);
--- a/jdk/test/javax/swing/JMenuItem/8158566/CloseOnMouseClickPropertyTest.java	Thu Jul 07 16:47:37 2016 +0530
+++ b/jdk/test/javax/swing/JMenuItem/8158566/CloseOnMouseClickPropertyTest.java	Thu Jul 07 15:39:19 2016 +0300
@@ -37,7 +37,7 @@
 
 /*
  * @test
- * @bug 8158566
+ * @bug 8158566 8160879
  * @summary Provide a Swing property which modifies MenuItemUI behaviour
  */
 public class CloseOnMouseClickPropertyTest {