diff options
author | Peter Wu <peter@lekensteyn.nl> | 2019-11-27 00:44:55 +0000 |
---|---|---|
committer | Roland Knall <rknall@gmail.com> | 2019-11-28 14:13:57 +0000 |
commit | 2d12ec67a37d27c4d924a628c7e657762cda8bd4 (patch) | |
tree | 33eea71d5081a20018528c5817b99b21b0c5538c /doc | |
parent | 43701644196eba7b0114bf882ebb48fe35669816 (diff) |
Qt: fix erratic expansion of tree item when switching packets
ProtoTree::setRootNode() is designed to update the model with the new
packet tree, and additionally expand tree items in its view. When the
current selected packet is changed, it must use this method to ensure
that collapsed trees are properly expanded. Fix this regression.
It was not entirely clear that framesSelected can no longer use previous
state, so document it explicitly. Remove the call to QTreeView::reset(),
it ends up calling QAbstractItemView::reset() which touches the
selection model that refers invalidated proto_node memory. The reset
function of the view is automatically called the model is reset, so the
call was not needed anyway.
Test: open test/captures/tls13-rfc8446.pcap, expand TLS, TLS Record, and
select "Content Type". Change from frame 1 to 2, and then 3. Observe
that the expanded state remains constant with no flickering. In frame 3,
observe that the tree remains expanded even if no item is selected.
Change-Id: I0c820711f1a62aa51ac100f8ac5c89265c51eb18
Fixes: v3.3.0rc0-6-gcfee0f8082 ("Qt: Remove frameSelect signal")
Reviewed-on: https://code.wireshark.org/review/35230
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Roland Knall <rknall@gmail.com>
Diffstat (limited to 'doc')
0 files changed, 0 insertions, 0 deletions