提交 c1a7cd13 编写于 作者: P peterz

6882917: Nimbus and DefaultTableCellRenderer: must start with normal background

Reviewed-by: rupashka
上级 24b614b1
......@@ -638,7 +638,7 @@ class SynthTableUI extends BasicTableUI implements SynthUI,
if ((b == null || b instanceof UIResource
|| component instanceof SynthBooleanTableCellRenderer)
&& !table.isCellSelected(row, column)) {
if (alternateColor != null && row % 2 == 0) {
if (alternateColor != null && row % 2 != 0) {
component.setBackground(alternateColor);
}
}
......
......@@ -214,8 +214,9 @@ public class DefaultTableCellRenderer extends JLabel
: table.getBackground();
if (background == null || background instanceof javax.swing.plaf.UIResource) {
Color alternateColor = DefaultLookup.getColor(this, ui, "Table.alternateRowColor");
if (alternateColor != null && row % 2 == 0)
if (alternateColor != null && row % 2 != 0) {
background = alternateColor;
}
}
super.setForeground(unselectedForeground != null
? unselectedForeground
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册