summaryrefslogtreecommitdiff
path: root/library/statistics.cpp
diff options
context:
space:
mode:
authorDaniel Wilhelm <daniel@wili.li>2014-04-18 17:07:43 +0200
committerDaniel Wilhelm <daniel@wili.li>2014-04-18 17:07:43 +0200
commit4226e548662339ea1ca37b45385a7cf9b237ff1e (patch)
tree9a3fa54b85d97f05164e41bdb96b82f748a37342 /library/statistics.cpp
parent3.7 (diff)
downloadFreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.tar.gz
FreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.tar.bz2
FreeFileSync-4226e548662339ea1ca37b45385a7cf9b237ff1e.zip
3.8
Diffstat (limited to 'library/statistics.cpp')
-rw-r--r--library/statistics.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/library/statistics.cpp b/library/statistics.cpp
index fc140add..3a6970d9 100644
--- a/library/statistics.cpp
+++ b/library/statistics.cpp
@@ -31,11 +31,12 @@ RetrieveStatistics::~RetrieveStatistics()
for (std::vector<statEntry>::const_iterator i = data.begin(); i != data.end(); ++i)
{
- outputFile.Write(FreeFileSync::numberToWxString(static_cast<int>(i->time), false));
+ using globalFunctions::numberToString;
+ outputFile.Write(numberToString(i->time));
outputFile.Write(wxT(";"));
- outputFile.Write(FreeFileSync::numberToWxString(i->objects, false));
+ outputFile.Write(numberToString(i->objects));
outputFile.Write(wxT(";"));
- outputFile.Write(FreeFileSync::numberToWxString(static_cast<int>(i->value), false));
+ outputFile.Write(numberToString(i->value));
outputFile.Write(wxT("\n"));
}
}
@@ -63,6 +64,10 @@ bool isNull(double number)
inline
wxString Statistics::formatRemainingTime(double timeInMs) const
{
+#ifndef _MSC_VER
+#warning adapt units "%x sec"
+#endif
+
bool unitSec = true;
double remainingTime = timeInMs / 1000;
wxString unit = _(" sec");
@@ -83,7 +88,6 @@ wxString Statistics::formatRemainingTime(double timeInMs) const
}
}
-
int formattedTime = globalFunctions::round(remainingTime);
//reduce precision to 5 seconds
@@ -104,7 +108,7 @@ wxString Statistics::formatRemainingTime(double timeInMs) const
}
remainingTimeLast = formattedTime;
- return FreeFileSync::numberToWxString(formattedTime, false) + unit;
+ return globalFunctions::numberToString(formattedTime) + unit;
//+ wxT("(") + globalFunctions::numberToWxString(globalFunctions::round(timeInMs / 1000)) + wxT(")");
}
bgstack15