summaryrefslogtreecommitdiff
path: root/Libraries
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-12-23 00:13:08 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-12-23 10:55:34 +0100
commitc1b4e8aef0a23c8e704758c9259acdc310aa8949 (patch)
treed793e36dfaea0f8958c5f158abb3601b20db3c66 /Libraries
parenta12c2df43f95b5dfbaa3c241845e5e62515c65fc (diff)
downloadserenity-c1b4e8aef0a23c8e704758c9259acdc310aa8949.zip
LibGUI: Activate GTreeView indexes when double clicking leaf nodes
This seems pretty sensible to me. I'm unsure if we should activate nodes that have children, or just toggle them.
Diffstat (limited to 'Libraries')
-rw-r--r--Libraries/LibGUI/GTreeView.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Libraries/LibGUI/GTreeView.cpp b/Libraries/LibGUI/GTreeView.cpp
index a579fe253f..e0c3283245 100644
--- a/Libraries/LibGUI/GTreeView.cpp
+++ b/Libraries/LibGUI/GTreeView.cpp
@@ -71,6 +71,8 @@ void GTreeView::doubleclick_event(GMouseEvent& event)
if (model.row_count(index))
toggle_index(index);
+ else
+ activate(index);
}
}