Skip to content

Commit 0d41edb

Browse files
committed
Fix #367
1 parent 8cdf917 commit 0d41edb

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/qt/peertablemodel.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ void PeerTableModel::refresh()
159159
// - https://doc.qt.io/qt-5/model-view-programming.html#resizable-models
160160
// We take advantage of the fact that the std::vector returned
161161
// by interfaces::Node::getNodesStats is sorted by nodeid.
162+
Q_EMIT layoutAboutToBeChanged();
162163
for (int i = 0; i < m_peers_data.size();) {
163164
if (i < new_peers_data.size() && m_peers_data.at(i).nodeStats.nodeid == new_peers_data.at(i).nodeStats.nodeid) {
164165
++i;
@@ -179,5 +180,5 @@ void PeerTableModel::refresh()
179180
m_peers_data.swap(new_peers_data);
180181
}
181182

182-
Q_EMIT changed();
183+
Q_EMIT layoutChanged();
183184
}

src/qt/rpcconsole.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -684,7 +684,7 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_
684684

685685
// peer table signal handling - update peer details when selecting new node
686686
connect(ui->peerWidget->selectionModel(), &QItemSelectionModel::selectionChanged, this, &RPCConsole::updateDetailWidget);
687-
connect(model->getPeerTableModel(), &PeerTableModel::changed, this, &RPCConsole::updateDetailWidget);
687+
connect(model->getPeerTableModel(), &PeerTableModel::layoutChanged, this, &RPCConsole::updateDetailWidget);
688688

689689
// set up ban table
690690
ui->banlistWidget->setModel(model->getBanTableModel());

0 commit comments

Comments
 (0)