code: @Override
      public void setComponentEnabled(boolean enabled) {
          super.setComponentEnabled(enabled);
  
          boolean enable = enabled && getModel().getRowCount() > 0;
          enableAllButton.setEnabled(enable);
          disableAllButton.setEnabled(enable);
      }
docs: {@inheritDoc}
  <p>
  Overridden to also enable/disable the added buttons ("enable all" and "disable all").
  </p>