aboutsummaryrefslogtreecommitdiff
path: root/src/qt/peertablemodel.cpp
diff options
context:
space:
mode:
authorJon Atack <jon@atack.com>2021-04-23 14:57:05 +0200
committerJarol Rodriguez <jarolrod@tutanota.com>2021-05-26 17:35:11 -0400
commit6971e790c32253ecddb6108e796afd3892ced7fe (patch)
tree348a43bffd422522f350b616ad91770a007e1404 /src/qt/peertablemodel.cpp
parent5c041cb348e667672c8b5ed504dba05adf60783b (diff)
gui: add Direction column to peers tab
Co-authored-by: Jarol Rodriguez <jarolrod@tutanota.com>
Diffstat (limited to 'src/qt/peertablemodel.cpp')
-rw-r--r--src/qt/peertablemodel.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/qt/peertablemodel.cpp b/src/qt/peertablemodel.cpp
index 11441481bb..1df02b7a93 100644
--- a/src/qt/peertablemodel.cpp
+++ b/src/qt/peertablemodel.cpp
@@ -113,8 +113,13 @@ QVariant PeerTableModel::data(const QModelIndex &index, int role) const
case NetNodeId:
return (qint64)rec->nodeStats.nodeid;
case Address:
- // prepend to peer address down-arrow symbol for inbound connection and up-arrow for outbound connection
- return QString::fromStdString((rec->nodeStats.fInbound ? "↓ " : "↑ ") + rec->nodeStats.addrName);
+ return QString::fromStdString(rec->nodeStats.addrName);
+ case Direction:
+ return QString(rec->nodeStats.fInbound ?
+ //: An Inbound Connection from a Peer.
+ tr("Inbound") :
+ //: An Outbound Connection to a Peer.
+ tr("Outbound"));
case ConnectionType:
return GUIUtil::ConnectionTypeToQString(rec->nodeStats.m_conn_type, /* prepend_direction */ false);
case Network:
@@ -134,6 +139,7 @@ QVariant PeerTableModel::data(const QModelIndex &index, int role) const
case NetNodeId:
case Address:
return {};
+ case Direction:
case ConnectionType:
case Network:
return QVariant(Qt::AlignCenter);