aspectRation handling for images, other then images types of downloads, progress fix, labels, context menu to open files

This commit is contained in:
Blue 2019-09-18 01:05:32 +03:00
parent 94a3766aaf
commit cc54c6393a
10 changed files with 307 additions and 80 deletions

View file

@ -115,8 +115,12 @@ void Core::NetworkAccess::onDownloadProgress(qint64 bytesReceived, qint64 bytesT
qDebug() << "an error downloading" << url << ": the request had some progress but seems like noone is waiting for it, skipping";
} else {
Download* dwn = itr->second;
qreal received = bytesReceived;
qreal total = bytesTotal;
qreal progress = received/total;
dwn->progress = progress;
for (std::set<QString>::const_iterator mItr = dwn->messages.begin(), end = dwn->messages.end(); mItr != end; ++mItr) {
emit downloadFileProgress(*mItr, bytesReceived/bytesTotal);
emit downloadFileProgress(*mItr, progress);
}
}
}