Skip to content

Commit

Permalink
fix custom arrow button color when clicked
Browse files Browse the repository at this point in the history
  • Loading branch information
akmsw committed Nov 20, 2024
1 parent f641654 commit aa65534
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public void paint(Graphics g) {
}

if (getModel().isPressed()) {
g.setColor(Constants.COLOR_GREEN_MEDIUM);
g.setColor(Constants.COLOR_GREEN_MEDIUM_LIGHT);
} else if (getModel().isRollover()) {
g.setColor(Constants.COLOR_GREEN_DARK_MEDIUM);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,7 @@ public static ComponentUI createUI(JComponent component) {
@Override
@SuppressWarnings({"java:S1190", "java:S117"})
protected void addButtonComponents(Container container, Object[] buttons, int initialIndex) {
if (buttons == null) {
return;
}

if (buttons.length <= 0) {
if ((buttons == null) || (buttons.length <= 0)) {
return;
}

Expand Down

0 comments on commit aa65534

Please sign in to comment.