OpenVPN bandwidth counter for Android

This commit is contained in:
Dmitriy Karpushin 2022-12-14 18:52:19 +03:00
parent 7345f464a5
commit d417fa58ab
7 changed files with 108 additions and 14 deletions

View file

@ -23,9 +23,7 @@
AndroidVpnProtocol::AndroidVpnProtocol(Proto protocol, const QJsonObject &configuration, QObject* parent)
: VpnProtocol(configuration, parent),
m_protocol(protocol)
{
}
{ }
ErrorCode AndroidVpnProtocol::start()
{
@ -39,3 +37,11 @@ void AndroidVpnProtocol::stop()
AndroidController::instance()->stop();
}
void AndroidVpnProtocol::connectionDataUpdated(QString totalRx, QString totalTx, QString endpoint, QString deviceIPv4)
{
quint64 rxBytes = totalRx.toLongLong();
quint64 txBytes = totalTx.toLongLong();
setBytesChanged(rxBytes, txBytes);
}

View file

@ -25,6 +25,9 @@ public:
signals:
public slots:
void connectionDataUpdated(QString totalRx, QString totalTx, QString endpoint, QString deviceIPv4);
protected slots:
protected: