@Override
  public void updateCustomComponent(@NotNull JComponent component, @NotNull Presentation presentation) {
    if (!(component instanceof SplitButton splitButton)) return;
    boolean shouldRepaint = splitButton.actionEnabled != presentation.isEnabled();
    splitButton.actionEnabled = presentation.isEnabled();
    if (shouldRepaint) splitButton.repaint();
  }
@Override
  public void updateCustomComponent(@NotNull JComponent component, @NotNull Presentation presentation)