Class TriStateCheckBoxTree.TriStateSelectionModel

java.lang.Object
javax.swing.tree.DefaultTreeSelectionModel
com.jidesoft.swing.CheckBoxTreeSelectionModel
com.inductiveautomation.ignition.client.util.gui.TriStateCheckBoxTree.TriStateSelectionModel
All Implemented Interfaces:
Serializable, Cloneable, EventListener, TreeModelListener, TreeSelectionModel
Enclosing class:
TriStateCheckBoxTree

public static class TriStateCheckBoxTree.TriStateSelectionModel extends com.jidesoft.swing.CheckBoxTreeSelectionModel
A CheckBoxTreeSelectionModel extended to support three checkbox states.
  • CHECKED — path is in the selection model's selection set
  • UNCHECKED — path is in neither set
  • PARTIAL — path is tracked in partialPaths; isPartiallySelected(TreePath) returns true
See Also:
  • Method Details

    • isPartiallySelected

      public boolean isPartiallySelected(TreePath path)
      Overrides:
      isPartiallySelected in class com.jidesoft.swing.CheckBoxTreeSelectionModel
    • setChecked

      public void setChecked(TreePath path)
      Marks path as CHECKED (selected, not partial).
    • setPartial

      public void setPartial(TreePath path)
      Marks path as PARTIAL (indeterminate).

      Do NOT call removeSelectionPath here — that fires JIDE selection events which interfere with partial rendering. Call clearAll() before bulk state changes, then call tree.repaint() once afterward.

    • setUnchecked

      public void setUnchecked(TreePath path)
      Marks path as UNCHECKED (not selected, not partial).
    • clearPartialPaths

      public void clearPartialPaths()
      Clears only the partial paths, leaving the selection (checked state) untouched.
    • clearAll

      public void clearAll()
      Clears all checked and partial states.