@Override
  public void updateSelection() {
    if (myComponents.isEmpty()) {
      clear();
    }
    else {
      List<Integer> selection = new ArrayList<>();
      for (int i = 0, size = myComponents.size(); i < size && selection.size() < 2; i++) {
        if (myComponents.get(i).getSelection() == SelectionType.SELECTION) {
          selection.add(i);
        }
      }

      mySelectionIndex = -1;
      mySelectionLength = 0;
      myAllSelected = false;
      myMixSelection = false;

      int size = selection.size();

      if (size > 0) {
        mySelectionIndex = selection.get(0);
        mySelectionLength = 1;
        myMixSelection = size > 1;
      }

      fireSelectionEvent();
    }
  }
@Override
  public void updateSelection()