NPE fix
authorVassiliy.Kudryashov <Vassiliy.Kudryashov@jetbrains.com>
Thu, 28 Aug 2014 11:44:55 +0000 (15:44 +0400)
committerVassiliy.Kudryashov <Vassiliy.Kudryashov@jetbrains.com>
Thu, 28 Aug 2014 11:46:00 +0000 (15:46 +0400)
platform/platform-api/src/com/intellij/ui/table/JBTable.java

index cd430c07a4e4f818408577855e7d5acc34e23bf5..c1146be40aba9376bb383bdf160add9d4ff6a691 100644 (file)
@@ -743,7 +743,7 @@ public class JBTable extends JTable implements ComponentWithEmptyText, Component
 
     @Override
     public void setColor(Color color) {
-      if (!UIUtil.isUnderDarcula() || !JBTable.this.getBackground().equals(color)) {
+      if (color != null && (!UIUtil.isUnderDarcula() || !JBTable.this.getBackground().equals(color))) {
         //noinspection UseJBColor
         color = new Color(UIUtil.getGrayFilter().filterRGB(0, 0, color.getRGB()));
       }