aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2017-12-15 22:49:18 +0100
committerGerald Combs <gerald@wireshark.org>2017-12-15 23:56:41 +0000
commit3071356d9e3d07d3c0132af88e4e8af785deb3ee (patch)
tree6d8ab1410497784ddabc74b4104ba86565c0c8b7
parentadde937ed74926323b084713caf6fbba871d8791 (diff)
Qt: A node without a child can not be expanded
Change-Id: I28bb5797e8eab69c761e257b90a11c646d06cf68 Reviewed-on: https://code.wireshark.org/review/24845 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Reviewed-by: Roland Knall <rknall@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
-rw-r--r--ui/qt/utils/proto_node.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/qt/utils/proto_node.cpp b/ui/qt/utils/proto_node.cpp
index 0fc87f2..03a9b91 100644
--- a/ui/qt/utils/proto_node.cpp
+++ b/ui/qt/utils/proto_node.cpp
@@ -106,7 +106,7 @@ int ProtoNode::row()
bool ProtoNode::isExpanded() const
{
- if (node_ && node_->finfo && tree_expanded(node_->finfo->tree_type)) {
+ if (node_ && node_->finfo && node_->first_child && tree_expanded(node_->finfo->tree_type)) {
return true;
}
return false;