aboutsummaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2015-01-27 09:25:29 -0800
committerGerald Combs <gerald@wireshark.org>2015-01-27 21:26:14 +0000
commit3aab6fc90ecb06050de62149ce5e22e1cdf0ec01 (patch)
tree1d5842a0cd660b8e882b6b1b94e28faf5e6d9c3b /ui
parent99764223d2e7aa661036efd78501753d5e9af51c (diff)
Qt: Update packet list freeze/thaw behavior.
Move the clear() calls in gee320ef a bit earlier in the code to PacketList::freeze. No model means no packets. Bug: 10896 Change-Id: Ie440e3da4c5fb601048f4e94c8712ecf2d864d4f Reviewed-on: https://code.wireshark.org/review/6823 Reviewed-by: Sean Stalley <seanstalley@gmail.com> Reviewed-by: Gerald Combs <gerald@wireshark.org>
Diffstat (limited to 'ui')
-rw-r--r--ui/qt/packet_list.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/ui/qt/packet_list.cpp b/ui/qt/packet_list.cpp
index 8a07c432f4..57e2acc76a 100644
--- a/ui/qt/packet_list.cpp
+++ b/ui/qt/packet_list.cpp
@@ -647,6 +647,11 @@ void PacketList::freeze()
{
setUpdatesEnabled(false);
setModel(NULL);
+ // It looks like GTK+ sends a cursor-changed signal at this point but Qt doesn't
+ // call selectionChanged.
+ related_packet_delegate_.clear();
+ proto_tree_->clear();
+ byte_view_tab_->clear();
}
void PacketList::thaw()
@@ -654,10 +659,6 @@ void PacketList::thaw()
setModel(packet_list_model_);
setUpdatesEnabled(true);
setColumnVisibility();
- if (packet_list_model_->rowCount() == 0) {
- proto_tree_->clear();
- byte_view_tab_->clear();
- }
}
void PacketList::clear() {