MCPcopy Create free account
hub / github.com/KangLin/RabbitRemoteControl / slotCalculating

Method slotCalculating

Src/ParameterCompone/Stats.cpp:99–113  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97}
98
99void CStats::slotCalculating()
100{
101 qint64 interval = m_lastTime.msecsTo(QDateTime::currentDateTime());
102
103 if(interval > 0) {
104 m_dbSendRate = (double)(m_TotalSends - m_lastSends) * 1000 / interval;
105 m_dbReceiveRate = (double)(m_TotalReceives - m_lastReceives) * 1000 / interval;
106 }
107
108 if(interval >= GetInterval() * 1000) {
109 m_lastSends = m_TotalSends;
110 m_lastReceives = m_TotalReceives;
111 m_lastTime = QDateTime::currentDateTime();
112 }
113}
114
115int CStats::OnLoad(QSettings &set)
116{

Callers 1

foreachFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected