Browse Source

Fixed ComboBox border NPE

pull/75/head
weisj 5 years ago
parent
commit
44f8a81854
  1. 2
      core/src/main/java/com/github/weisj/darklaf/ui/combobox/DarkComboBoxUI.java

2
core/src/main/java/com/github/weisj/darklaf/ui/combobox/DarkComboBoxUI.java

@ -74,7 +74,6 @@ public class DarkComboBoxUI extends BasicComboBoxUI implements Border, PropertyC
@Override
public void installUI(final JComponent c) {
super.installUI(c);
comboBox.setBorder(this);
boxPadding = UIManager.getInsets("ComboBox.insets");
borderSize = UIManager.getInt("ComboBox.borderThickness");
background = UIManager.getColor("ComboBox.activeBackground");
@ -89,6 +88,7 @@ public class DarkComboBoxUI extends BasicComboBoxUI implements Border, PropertyC
cellPadding = UIManager.getInsets("ComboBox.cellEditorInsets");
if (boxPadding == null) boxPadding = new Insets(0, 0, 0, 0);
if (cellPadding == null) cellPadding = new Insets(0, 0, 0, 0);
comboBox.setBorder(this);
}
@Override

Loading…
Cancel
Save