Enable the overall file count in progress again.

This commit is contained in:
Klaas Freitag 2013-11-21 11:37:47 +01:00
parent 55e82ee4c1
commit 8d2950f66c
2 changed files with 14 additions and 1 deletions

View File

@ -580,11 +580,23 @@ void CSyncThread::slotProgress(Progress::Kind kind, const QString &file, quint64
{
Progress::Info pInfo = _progressInfo;
if( kind == Progress::StartSync ) {
QMutexLocker lock(&_mutex);
_currentFileNo = 0;
}
if( kind == Progress::StartDelete ||
kind == Progress::StartDownload ||
kind == Progress::StartRename ||
kind == Progress::StartUpload ) {
QMutexLocker lock(&_mutex);
_currentFileNo += 1;
}
pInfo.kind = kind;
pInfo.current_file = file;
pInfo.file_size = total;
pInfo.current_file_bytes = curr;
pInfo.current_file_no = _currentFileNo;
pInfo.overall_current_bytes += curr;
pInfo.timestamp = QDateTime::currentDateTime();

View File

@ -112,6 +112,7 @@ private:
Progress::Info _progressInfo;
int _downloadLimit;
int _uploadLimit;
int _currentFileNo;
QAtomicInt _abortRequested;