AvaloniaUI / Avalonia.Controls.TreeDataGrid

A combined TreeView/DataGrid for Avalonia.
MIT License
234 stars 49 forks source link

Cannot expand nodes with the keyboard after collapsing them #211

Closed danipen closed 10 months ago

danipen commented 10 months ago

The following sequence of actions reproduces the case.

Check the following video for a complete repro:

https://github.com/AvaloniaUI/Avalonia.Controls.TreeDataGrid/assets/501613/f62b0d7a-83c4-4968-8318-50f18a4c2390

grokys commented 10 months ago

The problem is that when moving selection via the keyboard, the focus isn't updated, so when the root row is collapsed, the child row still has focus. Collapsing causes the child (focused) row to be removed from the tree causing focus to be set to null.