@Override
  public void layout() {
    if (table == null) return;

    table.setBounds(0, 0, table.getPrefWidth(), table.getPrefHeight());

    if (actionRunning == false) {
      if (collapsed) currentWidth = 0;
      else currentWidth = table.getPrefWidth();
    }
  }
 @Override
 public float getPrefHeight() {
   return table == null ? 0 : table.getPrefHeight();
 }