today I wanna share with you a MultiSelectionTreeView control that I coded by myself a couple of day ago.
The source code can be downloaded here.
Feel free to reply at this post with any question or comments you have.
The controller provide the following functionalities:
- three different selection modalities can be specified setting SelectionMode property. Supported Selection Modalities are:
- SingleSelectionOnly: same behaviors of classic WPF TreeView,
- MultipleSelectionOnly: every click select/unselect the clicked item,
- KeyboardModifiersMode: multiple select items when CTRL key is pressed
- retrieving selected nodes using SelectedItems property
- data binding support, including HierarchicalDataTemplate
- tree navigation using arrows keyboards up, down and left, right for expanding and collapsing nodes
- helpful TreeItem nodes methods like:
- GetNextNodeAtSameLevel, GetPreviousNodeAtSameLevel
- look and feel can be overridden
The default look and feel is shown in the picture below: