diff options
author | Philip Kaufmann <phil.kaufmann@t-online.de> | 2014-06-03 14:42:20 +0200 |
---|---|---|
committer | Philip Kaufmann <phil.kaufmann@t-online.de> | 2014-06-03 15:01:50 +0200 |
commit | bbe1925ce3e627fd405d83e3c947e1f430a1d720 (patch) | |
tree | c90ef9fe03b5f4cbb30ccd23ab42b1c43b26bb1f /src/qt/rpcconsole.cpp | |
parent | 4c097f9669a28420da74b159a4d61e509da80d33 (diff) |
[Qt] style police and small addition in rpcconsole
- fix spaces, indentation and coding style glitches
Diffstat (limited to 'src/qt/rpcconsole.cpp')
-rw-r--r-- | src/qt/rpcconsole.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/qt/rpcconsole.cpp b/src/qt/rpcconsole.cpp index ed048cf3cc..3b7d37ff39 100644 --- a/src/qt/rpcconsole.cpp +++ b/src/qt/rpcconsole.cpp @@ -10,10 +10,9 @@ #include "peertablemodel.h" #include "main.h" -#include "util.h" - #include "rpcserver.h" #include "rpcclient.h" +#include "util.h" #include "json/json_spirit_value.h" #include <openssl/crypto.h> @@ -297,10 +296,8 @@ void RPCConsole::setClientModel(ClientModel *model) // connect the peerWidget's selection model to our peerSelected() handler QItemSelectionModel *peerSelectModel = ui->peerWidget->selectionModel(); - connect(peerSelectModel, - SIGNAL(selectionChanged(const QItemSelection &, const QItemSelection &)), - this, - SLOT(peerSelected(const QItemSelection &, const QItemSelection &))); + connect(peerSelectModel, SIGNAL(selectionChanged(const QItemSelection &, const QItemSelection &)), + this, SLOT(peerSelected(const QItemSelection &, const QItemSelection &))); connect(model->getPeerTableModel(), SIGNAL(layoutChanged()), this, SLOT(peerLayoutChanged())); // Provide initial values @@ -511,6 +508,8 @@ void RPCConsole::updateTrafficStats(quint64 totalBytesIn, quint64 totalBytesOut) void RPCConsole::peerSelected(const QItemSelection &selected, const QItemSelection &deselected) { + Q_UNUSED(deselected); + if (selected.indexes().isEmpty()) return; @@ -638,6 +637,8 @@ void RPCConsole::updateNodeDetail(const CNodeCombinedStats *combinedStats) ui->peerBanScore->setText(tr("Fetching...")); } +// We override the virtual resizeEvent of the QWidget to adjust tables column +// sizes as the tables width is proportional to the dialogs width. void RPCConsole::resizeEvent(QResizeEvent *event) { QWidget::resizeEvent(event); @@ -651,7 +652,7 @@ void RPCConsole::showEvent(QShowEvent *event) // peerWidget needs a resize in case the dialog has non-default geometry columnResizingFixer->stretchColumnWidth(PeerTableModel::Address); - // start the PeerTableModel refresh timer + // start PeerTableModel auto refresh clientModel->getPeerTableModel()->startAutoRefresh(1000); } |