|
|
|
@ -1128,10 +1128,12 @@ void MainWindow::updateGUI() {
@@ -1128,10 +1128,12 @@ void MainWindow::updateGUI() {
|
|
|
|
|
html += "qBittorrent"; |
|
|
|
|
html += "</div>"; |
|
|
|
|
html += "<div style='vertical-align: baseline; height: 18px;'>"; |
|
|
|
|
html += "<img src=':/Icons/skin/download.png'/> "+tr("DL speed: %1 KiB/s", "e.g: Download speed: 10 KiB/s").arg(QString::number(QBtSession::instance()->getPayloadDownloadRate()/1024., 'f', 1)); |
|
|
|
|
/* HACK because QString rounds up. Eg QString::number(0.999*100.0, 'f' ,1) == 99.9
|
|
|
|
|
** but QString::number(0.9999*100.0, 'f' ,1) == 100.0 */ |
|
|
|
|
html += "<img src=':/Icons/skin/download.png'/> "+tr("DL speed: %1 KiB/s", "e.g: Download speed: 10 KiB/s").arg(QString::number((int)((QBtSession::instance()->getPayloadDownloadRate()/1024.)*10)/10.0, 'f', 1)); |
|
|
|
|
html += "</div>"; |
|
|
|
|
html += "<div style='vertical-align: baseline; height: 18px;'>"; |
|
|
|
|
html += "<img src=':/Icons/skin/seeding.png'/> "+tr("UP speed: %1 KiB/s", "e.g: Upload speed: 10 KiB/s").arg(QString::number(QBtSession::instance()->getPayloadUploadRate()/1024., 'f', 1)); |
|
|
|
|
html += "<img src=':/Icons/skin/seeding.png'/> "+tr("UP speed: %1 KiB/s", "e.g: Upload speed: 10 KiB/s").arg(QString::number((int)((QBtSession::instance()->getPayloadUploadRate()/1024.)*10)/10.0, 'f', 1)); |
|
|
|
|
html += "</div>"; |
|
|
|
|
#else |
|
|
|
|
// OSes such as Windows do not support html here
|
|
|
|
|