예제 #1
0
  /**
   * Selects multiple items in the tree view.
   *
   * @param components The components to select. Pass <code>null</code> to deselect everything
   *     currently selected.
   */
  public void selectItems(Set<ModelComponent> components) {
    Set<ModelComponent> visibleComponents = new HashSet<>();

    if (components != null) {
      for (ModelComponent comp : components) {
        if (comp.isTreeViewVisible()) {
          visibleComponents.add(comp);
        }
      }
    }

    fTreeView.selectItems(visibleComponents);
    OpenTCSView.instance().editingOptions(components);
  }
예제 #2
0
 /**
  * Selektiert ein Item im TreeView.
  *
  * @param component
  */
 public void selectItem(ModelComponent component) {
   if (component != null && component.isTreeViewVisible()) {
     fTreeView.selectItem(component);
     Set<ModelComponent> comps = new HashSet<>(1);
     comps.add(component);
     OpenTCSView.instance().editingOptions(comps);
   }
 }
예제 #3
0
 /**
  * Erstellt die Baumansicht für die übergebene Komponente des Systemmodells. Dieser Aufruf ergeht
  * dann rekursiv an alle Kindkomponenten.
  *
  * @param component
  */
 public void restoreTreeView(ModelComponent component) {
   component.treeRestore(null, this);
 }