Qt: Don't fill in the packet diagram if it's not visible.
Don't bother filling in our scene if the widget isn't visible.
This commit is contained in:
parent
adfded498a
commit
3b9656780b
|
@ -364,8 +364,12 @@ PacketDiagram::~PacketDiagram()
|
|||
|
||||
void PacketDiagram::setRootNode(proto_node *root_node)
|
||||
{
|
||||
scene()->clear();
|
||||
root_node_ = root_node;
|
||||
if (!isVisible()) {
|
||||
return;
|
||||
}
|
||||
|
||||
scene()->clear();
|
||||
selected_field_ = nullptr;
|
||||
y_pos_ = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue