From e6ddc7e0226b7432c3360f1e11dd605fecdb4bab Mon Sep 17 00:00:00 2001 From: thankyouverycool <66646555+thankyouverycool@users.noreply.github.com> Date: Fri, 10 Jul 2020 09:47:58 -0400 Subject: [PATCH] LibGUI: Add missing on_toggle hook to TreeView Alt+arrow toggles are now captured. --- Libraries/LibGUI/TreeView.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Libraries/LibGUI/TreeView.cpp b/Libraries/LibGUI/TreeView.cpp index 583080c7cc..c3bbda16f9 100644 --- a/Libraries/LibGUI/TreeView.cpp +++ b/Libraries/LibGUI/TreeView.cpp @@ -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); }