jdk/src/macosx/classes/com/apple/laf/AquaTabbedPaneCopyFromBasicUI.java
changeset 19173 5c179adfb12b
parent 12047 320a714614e9
child 21278 ef8a3a2a72f2
--- a/jdk/src/macosx/classes/com/apple/laf/AquaTabbedPaneCopyFromBasicUI.java	Thu Aug 01 01:26:57 2013 +0400
+++ b/jdk/src/macosx/classes/com/apple/laf/AquaTabbedPaneCopyFromBasicUI.java	Thu Aug 01 17:09:59 2013 +0400
@@ -1856,7 +1856,10 @@
         // If we're not valid that means we will shortly be validated and
         // painted, which means we don't have to do anything here.
         if (!isRunsDirty && index >= 0 && index < tabPane.getTabCount()) {
-            tabPane.repaint(getTabBounds(tabPane, index));
+            Rectangle rect = getTabBounds(tabPane, index);
+            if (rect != null) {
+                tabPane.repaint(rect);
+            }
         }
     }