adjustments due to changed chrono API

This commit is contained in:
Martchus 2015-09-12 17:59:43 +02:00
parent 231c705d0d
commit d5b880a22a
2 changed files with 3 additions and 2 deletions

View File

@ -371,7 +371,7 @@ bool NetworkStatsOptionPage::apply()
void NetworkStatsOptionPage::reset()
{
if(hasBeenShown()) {
m_receivedLabel->setText(QStringLiteral("%1 (%2 bytes)").arg(QString::fromStdString(ConversionUtilities::dataSizeToString(bytesReceived())), QString::number(bytesReceived())));
m_receivedLabel->setText(QString::fromStdString(ConversionUtilities::dataSizeToString(bytesReceived(), true)));
}
}

View File

@ -5,6 +5,7 @@
#include <QUrlQuery>
using namespace Application;
using namespace ChronoUtilities;
namespace Network {
@ -112,7 +113,7 @@ void SockshareDownload::evalVideoInformation(Download *, QBuffer *videoInfoBuffe
if(substring(videoInfo, str, pos, QStringLiteral("duration=\""), QStringLiteral("\""))) {
bool ok;
int duration = str.toInt(&ok);
if(ok) setDuration(duration);
if(ok) setDuration(TimeSpan(duration));
}
reportInitiated(true);
}