aboutsummaryrefslogtreecommitdiff
path: root/src/qt/clientmodel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/qt/clientmodel.cpp')
-rw-r--r--src/qt/clientmodel.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/qt/clientmodel.cpp b/src/qt/clientmodel.cpp
index b244bc94f2..04161020b2 100644
--- a/src/qt/clientmodel.cpp
+++ b/src/qt/clientmodel.cpp
@@ -8,6 +8,7 @@
#include <qt/guiconstants.h>
#include <qt/guiutil.h>
#include <qt/peertablemodel.h>
+#include <qt/peertablesortproxy.h>
#include <clientversion.h>
#include <interfaces/handler.h>
@@ -38,7 +39,11 @@ ClientModel::ClientModel(interfaces::Node& node, OptionsModel *_optionsModel, QO
{
cachedBestHeaderHeight = -1;
cachedBestHeaderTime = -1;
+
peerTableModel = new PeerTableModel(m_node, this);
+ m_peer_table_sort_proxy = new PeerTableSortProxy(this);
+ m_peer_table_sort_proxy->setSourceModel(peerTableModel);
+
banTableModel = new BanTableModel(m_node, this);
QTimer* timer = new QTimer;
@@ -184,6 +189,11 @@ PeerTableModel *ClientModel::getPeerTableModel()
return peerTableModel;
}
+PeerTableSortProxy* ClientModel::peerTableSortProxy()
+{
+ return m_peer_table_sort_proxy;
+}
+
BanTableModel *ClientModel::getBanTableModel()
{
return banTableModel;
@@ -216,7 +226,7 @@ QString ClientModel::dataDir() const
QString ClientModel::blocksDir() const
{
- return GUIUtil::boostPathToQString(GetBlocksDir());
+ return GUIUtil::boostPathToQString(gArgs.GetBlocksDirPath());
}
void ClientModel::updateBanlist()