IDEA-81876 blank line shows for selection

This commit is contained in:
irengrig
2012-02-27 14:14:46 +04:00
parent e3adb83531
commit 4dad6c3c7c
@@ -436,6 +436,12 @@ public class UIUtil {
}
public static Color getTreeSelectionBackground() {
if (isUnderNimbusLookAndFeel()) {
Color color = UIManager.getColor("Tree.nimbusSelectionBackground");
if (color != null) return color;
color = UIManager.getColor("nimbusSelectionBackground");
if (color != null) return color;
}
return UIManager.getColor("Tree.selectionBackground");
}
@@ -456,6 +462,12 @@ public class UIUtil {
}
public static Color getTableSelectionBackground() {
if (isUnderNimbusLookAndFeel()) {
Color color = UIManager.getColor("Table.nimbusSelectionBackground");
if (color != null) return color;
color = UIManager.getColor("nimbusSelectionBackground");
if (color != null) return color;
}
return UIManager.getColor("Table.selectionBackground");
}
@@ -613,6 +625,12 @@ public class UIUtil {
}
public static Color getListSelectionBackground() {
if (isUnderNimbusLookAndFeel()) {
Color color = UIManager.getColor("List.nimbusSelectionBackground");
if (color != null) return color;
color = UIManager.getColor("nimbusSelectionBackground");
if (color != null) return color;
}
final Color color = UIManager.getColor("List.selectionBackground");
if (color == null) {
return UIManager.getColor("List[Selected].textBackground"); // Nimbus