mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-25 07:29:33 -05:00
Call RsControl::ConfigGetDataRates only once a second in the QTimer in MainWindow.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3707 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
8d992ec817
commit
741948acff
@ -504,7 +504,7 @@ void MainWindow::updateStatus()
|
||||
rsicontrol -> ConfigGetDataRates(downKb, upKb);
|
||||
|
||||
if (ratesstatus)
|
||||
ratesstatus->getRatesStatus();
|
||||
ratesstatus->getRatesStatus(downKb, upKb);
|
||||
|
||||
if (peerstatus)
|
||||
peerstatus->getPeerStatus(nFriendCount, nOnlineCount);
|
||||
|
@ -47,12 +47,9 @@ RatesStatus::RatesStatus(QWidget *parent)
|
||||
setLayout(hbox);
|
||||
}
|
||||
|
||||
void RatesStatus::getRatesStatus()
|
||||
void RatesStatus::getRatesStatus(float downKb, float upKb)
|
||||
{
|
||||
/* set users/friends/network */
|
||||
float downKb = 0;
|
||||
float upKb = 0;
|
||||
rsicontrol -> ConfigGetDataRates(downKb, upKb);
|
||||
|
||||
std::ostringstream out;
|
||||
out << std::setprecision(2) << std::fixed << downKb ;
|
||||
|
@ -32,7 +32,7 @@ class RatesStatus : public QWidget
|
||||
public:
|
||||
RatesStatus(QWidget *parent = 0);
|
||||
|
||||
void getRatesStatus( );
|
||||
void getRatesStatus(float downKb, float upKb);
|
||||
|
||||
private:
|
||||
QLabel *iconLabel, *statusRates;
|
||||
|
Loading…
Reference in New Issue
Block a user