You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using r712 on Windows 7 SP1 and I have noticed a strange behavior when moving between nodes using the keyboard.
I have plugged the OnAddToSelection event and I am using the GetFirstSelected/GetNextSelected construct to get the nodes that are selected.
However, when the newly selected node (parameter to OnAddToSelection) does not come up in the GetFirstSelected iteration.
If I use the mouse and the OnFocusChanged event, I do get the appropriate enumeration with GetFirstSelected.
So right now, I can have a valid selection with the mouse, but I'm stuck when using the keyboard.
I have attached a small sample application that shows the behavior, please let me know if I missed something obvious.
The reason for this behavior is that FSelectionCount is updated at the end of InternalAddToSelection(), and the OnAddToSelection event is fired before, for every node in the passed array.
Idea: We could store the original FSelectionCount in a local variable OldSelectionCount and increment FSelectionCount each time we fire the OnAddToSelection event. At the end we can set FSelectionCount := OldSelectionCount + NewLength;
From [email protected] on October 10, 2014 00:54:17
Hello,
I am using r712 on Windows 7 SP1 and I have noticed a strange behavior when moving between nodes using the keyboard.
I have plugged the OnAddToSelection event and I am using the GetFirstSelected/GetNextSelected construct to get the nodes that are selected.
However, when the newly selected node (parameter to OnAddToSelection) does not come up in the GetFirstSelected iteration.
If I use the mouse and the OnFocusChanged event, I do get the appropriate enumeration with GetFirstSelected.
So right now, I can have a valid selection with the mouse, but I'm stuck when using the keyboard.
I have attached a small sample application that shows the behavior, please let me know if I missed something obvious.
Attachment: keyboard selection.zip
Original issue: http://code.google.com/p/virtual-treeview/issues/detail?id=487
The text was updated successfully, but these errors were encountered: