mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-24 16:51:25 -04:00
forgot to commit this patch to make the bandwidth graph refresh rate smoother
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5590 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
1c3d6e7c16
commit
0cb0a9b0f9
3 changed files with 11 additions and 9 deletions
|
@ -1,7 +1,7 @@
|
|||
/****************************************************************
|
||||
* This file is distributed under the following license:
|
||||
*
|
||||
* Copyright (c) 2006-2007, crypton
|
||||
* This file is distributed under the following license:
|
||||
*
|
||||
* Copyright (c) 2006-2007, crypton
|
||||
* Copyright (c) 2006, Matt Edman, Justin Hipple
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
|
@ -25,6 +25,7 @@
|
|||
#include <QtGlobal>
|
||||
|
||||
#include "graphframe.h"
|
||||
#include "gui/bwgraph/bwgraph.h"
|
||||
|
||||
|
||||
/** Default contructor */
|
||||
|
@ -79,9 +80,10 @@ GraphFrame::addPoints(qreal recv, qreal send)
|
|||
_recvData->prepend(recv);
|
||||
|
||||
/* Add to the total counters */
|
||||
_totalSend += send;
|
||||
_totalRecv += recv;
|
||||
|
||||
/* These are not the real total values, but should be close enough. */
|
||||
_totalSend += BWGRAPH_REFRESH_RATE * send / 1000;
|
||||
_totalRecv += BWGRAPH_REFRESH_RATE * recv / 1000;
|
||||
|
||||
/* Check for a new maximum value */
|
||||
if (send > _maxValue) _maxValue = send;
|
||||
if (recv > _maxValue) _maxValue = recv;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue