Intention: To display the busy/Wait cursor for the duration that the children of the node are populated.
Seems to be hidden in WPF. I remember having some kind of event in Winforms Tree Control where you could subscribe to - to achieve this.
Currently I have a TreeView which has a number of listviews tied to its SelectedItem. All controls are databound and use DataTemplates to display the items. The code is functional. But when I expand a tree-node with a lot of children, the UI goes sluggish.. it looks like the click didnt register.. and I being the impatient user go clickety-click on the node.
So how do I do this ? I'd like to set the Cursor to Wait in BeforeExpand and reset in AfterExpand.
Code Scribble:
<HierarchicalDataTemplate DataType="{x:Type local:LinqToSqlNodeClass}" ItemsSource="{Binding Path=Children}">
// visual representation
</HierarchicalDataTemplate>
// more typed data templates
<TreeView ItemsSource="{Binding Path=Nodes}" />