mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-13 03:22:34 -04:00
Added a graphframe to Bandwidth Control Window and Turtle Router Statistics Dialog
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7500 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
6085ccd43f
commit
29a11b021e
10 changed files with 751 additions and 117 deletions
|
@ -283,6 +283,9 @@ void BwCtrlWindow::updateBandwidth()
|
|||
/* insert */
|
||||
QTreeWidgetItem *item = new QTreeWidgetItem();
|
||||
peerTreeWidget->addTopLevelItem(item);
|
||||
peerTreeWidget->setSelectionMode(QAbstractItemView::SingleSelection);
|
||||
|
||||
updateGraph(totalRates.mRateIn,totalRates.mRateOut);
|
||||
|
||||
/* do Totals */
|
||||
item -> setData(COLUMN_PEERID, Qt::DisplayRole, tr("TOTALS"));
|
||||
|
@ -420,5 +423,10 @@ void BwCtrlWindow::updateBandwidth()
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
/** Adds new data to the graph. */
|
||||
void BwCtrlWindow::updateGraph(qreal bytesRead, qreal bytesWritten)
|
||||
{
|
||||
/* Graph only cares about kilobytes */
|
||||
ui->frmGraph->addPoints(bytesRead/*/1024.0*/, bytesWritten/*/1024.0*/);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue