summaryrefslogtreecommitdiff
path: root/library/statistics.cpp
diff options
context:
space:
mode:
authorDaniel Wilhelm <daniel@wili.li>2014-04-18 17:12:46 +0200
committerDaniel Wilhelm <daniel@wili.li>2014-04-18 17:12:46 +0200
commitb338e29fd3eaf700f8c8360aa0310048ba941d54 (patch)
tree122f8ef3790d12cd10275ef7453a9e8053322d78 /library/statistics.cpp
parent3.18 (diff)
downloadFreeFileSync-b338e29fd3eaf700f8c8360aa0310048ba941d54.tar.gz
FreeFileSync-b338e29fd3eaf700f8c8360aa0310048ba941d54.tar.bz2
FreeFileSync-b338e29fd3eaf700f8c8360aa0310048ba941d54.zip
3.19
Diffstat (limited to 'library/statistics.cpp')
-rw-r--r--library/statistics.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/statistics.cpp b/library/statistics.cpp
index c2ba8c0c..812c869b 100644
--- a/library/statistics.cpp
+++ b/library/statistics.cpp
@@ -136,7 +136,6 @@ wxString Statistics::formatRemainingTime(double timeInMs) const
}
output.Replace(wxT("%x"), zen::toStringSep(formattedTime));
return output;
- //+ wxT("(") + common::numberToWxString(common::round(timeInMs / 1000)) + wxT(")");
}
@@ -227,7 +226,8 @@ wxString Statistics::getBytesPerSecond() const
const double dataDelta = backRecord.second.data - frontRecord.second.data;
if (!isNull(timeDelta))
- return zen::formatFilesizeToShortString(zen::UInt64(dataDelta * 1000 / timeDelta)) + _("/sec");
+ if (dataDelta > 0) //may be negative if user cancels copying
+ return zen::formatFilesizeToShortString(zen::UInt64(dataDelta * 1000 / timeDelta)) + _("/sec");
}
return wxT("-"); //fallback
bgstack15