harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hinde...@apache.org
Subject svn commit: r496096 - in /harmony/enhanced/classlib/trunk/modules/swing: make/ src/main/java/common/javax/swing/plaf/basic/ src/test/api/java/common/javax/swing/plaf/basic/
Date Sun, 14 Jan 2007 17:05:26 GMT
Author: hindessm
Date: Sun Jan 14 09:05:24 2007
New Revision: 496096

URL: http://svn.apache.org/viewvc?view=rev&rev=496096
Log:
Applying patches from "[#HARMONY-2695] [classlib][swing]
javax.swing.plaf.basic.BasicCheckBoxMenuItemUI.getMinimumSize(null)/getMaxi
mumSize(null) returns null while RI throws NPE".

Modified:
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.drl
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.ibm
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.drl
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.ibm
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.drl
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.ibm
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.drl
    harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.ibm
    harmony/enhanced/classlib/trunk/modules/swing/src/main/java/common/javax/swing/plaf/basic/BasicMenuItemUI.java
    harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
    harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicMenuItemUITest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.drl
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.drl?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.drl (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.drl Sun Jan 14 09:05:24
2007
@@ -72,7 +72,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.ibm
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.ibm?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.ibm (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86.ibm Sun Jan 14 09:05:24
2007
@@ -72,7 +72,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.drl
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.drl?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.drl (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.drl Sun Jan 14
09:05:24 2007
@@ -75,7 +75,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.ibm
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.ibm?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.ibm (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.linux.x86_64.ibm Sun Jan 14
09:05:24 2007
@@ -72,7 +72,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.drl
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.drl?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.drl (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.drl Sun Jan 14
09:05:24 2007
@@ -76,7 +76,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.ibm
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.ibm?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.ibm (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86.ibm Sun Jan 14
09:05:24 2007
@@ -83,7 +83,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.drl
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.drl?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.drl (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.drl Sun Jan
14 09:05:24 2007
@@ -72,7 +72,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.ibm
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.ibm?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.ibm (original)
+++ harmony/enhanced/classlib/trunk/modules/swing/make/exclude.windows.x86_64.ibm Sun Jan
14 09:05:24 2007
@@ -72,7 +72,6 @@
 javax/swing/SortingFocusTraversalPolicyRTest.java
 javax/swing/SwingUtilitiesRTest.java
 javax/swing/SwingUtilitiesTest.java
-javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
 javax/swing/plaf/basic/BasicComboPopupTest.java
 javax/swing/plaf/basic/BasicEditorPaneUITest.java
 javax/swing/plaf/basic/BasicGraphicsUtilsTest.java

Modified: harmony/enhanced/classlib/trunk/modules/swing/src/main/java/common/javax/swing/plaf/basic/BasicMenuItemUI.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/src/main/java/common/javax/swing/plaf/basic/BasicMenuItemUI.java?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/src/main/java/common/javax/swing/plaf/basic/BasicMenuItemUI.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/swing/src/main/java/common/javax/swing/plaf/basic/BasicMenuItemUI.java
Sun Jan 14 09:05:24 2007
@@ -303,6 +303,9 @@
     }
 
     public Dimension getMinimumSize(final JComponent c) {
+        if (c == null) {
+            throw new NullPointerException("component is null");
+        }
         return null;
     }
 
@@ -311,6 +314,9 @@
     }
 
     public Dimension getMaximumSize(final JComponent c) {
+        if (c == null) {
+            throw new NullPointerException("component is null");
+        }
         return null;
     }
 

Modified: harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicCheckBoxMenuItemUITest.java
Sun Jan 14 09:05:24 2007
@@ -64,4 +64,22 @@
      */
     public void testProcessMouseEvent() {
     }
+
+    /*
+     * Test method for 'javax.swing.plaf.basic.BasicCheckBoxMenuItemUI.getMinimumSize(null)/getMaximumSize(null)'
+     */
+    public void testGetSizes() {
+        try { //Regression test for HARMONY-2695
+            checkBoxUI.getMinimumSize(null);
+            fail("NullPointerException should have been thrown");
+        } catch (NullPointerException e) {
+            // Expected
+        }
+        try { //Regression test for HARMONY-2695
+            checkBoxUI.getMaximumSize(null);
+            fail("NullPointerException should have been thrown");
+        } catch (NullPointerException e) {
+            // Expected
+        }
+    }
 }

Modified: harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicMenuItemUITest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicMenuItemUITest.java?view=diff&rev=496096&r1=496095&r2=496096
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicMenuItemUITest.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/swing/src/test/api/java/common/javax/swing/plaf/basic/BasicMenuItemUITest.java
Sun Jan 14 09:05:24 2007
@@ -122,6 +122,18 @@
         assertEquals(menuItemUI.getPreferredMenuItemSize(item, menuItemUI.checkIcon,
                 menuItemUI.arrowIcon, menuItemUI.defaultTextIconGap), menuItemUI
                 .getPreferredSize(item));
+        try { //Regression test for HARMONY-2695
+            menuItemUI.getMinimumSize(null);
+            fail("NullPointerException should have been thrown");
+        } catch (NullPointerException e) {
+            // Expected
+        }
+        try { //Regression test for HARMONY-2695
+            menuItemUI.getMaximumSize(null);
+            fail("NullPointerException should have been thrown");
+        } catch (NullPointerException e) {
+            // Expected
+        }
     }
 
     /*



Mime
View raw message