Class TreeViewItemSelectionBehavior
Taken from https://stackoverflow.com/questions/1000040/data-binding-to-selecteditem-in-a-wpf-treeview The existing TreeViewNodeSelectionBehavior does more work then I believe necessary, but the Token Tree is using it so I didn't want to remove it yet.
Inheritance
TreeViewItemSelectionBehavior
Inherited Members
Namespace: Phoenix.Aruba.Behaviors
Assembly: Phoenix.Plugin.Aruba.dll
Syntax
public class TreeViewItemSelectionBehavior : Behavior<TreeView>, IAnimatable, IAttachedObject
Fields
View SourceSelectedItemProperty
A property for the selected item.
Declaration
public static readonly DependencyProperty SelectedItemProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
Properties
View SourceSelectedItem
Gets or sets the selected item.
Declaration
public object SelectedItem { get; set; }
Property Value
Type | Description |
---|---|
object |
Methods
View SourceOnAttached()
Update that the selected item changed.
Declaration
protected override void OnAttached()
Overrides
View SourceOnDetaching()
Update that the selected item changed.
Declaration
protected override void OnDetaching()
Overrides
Implements
Microsoft.Xaml.Behaviors.IAttachedObject