mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-29 21:00:06 +00:00
LibGUI: Add missing on_toggle hook to TreeView
Alt+arrow toggles are now captured.
This commit is contained in:
committed by
Andreas Kling
parent
bd0a4cbbf9
commit
e6ddc7e022
@@ -115,6 +115,8 @@ void TreeView::set_open_state_of_all_in_subtree(const ModelIndex& root, bool ope
|
||||
int row_count = model()->row_count(root);
|
||||
int column = model()->tree_column();
|
||||
for (int row = 0; row < row_count; ++row) {
|
||||
if (on_toggle)
|
||||
on_toggle(root, open);
|
||||
auto index = model()->index(row, column, root);
|
||||
set_open_state_of_all_in_subtree(index, open);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user