From 9b623ea3943165fe7efb5e47a0b5b9452c1599e6 Mon Sep 17 00:00:00 2001 From: Daniel Wilhelm Date: Wed, 9 May 2018 00:09:55 +0200 Subject: 9.8 --- zen/format_unit.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'zen/format_unit.cpp') diff --git a/zen/format_unit.cpp b/zen/format_unit.cpp index 0f54a34b..09134c07 100755 --- a/zen/format_unit.cpp +++ b/zen/format_unit.cpp @@ -5,7 +5,6 @@ // ***************************************************************************** #include "format_unit.h" -//#include //swprintf #include #include #include "basic_math.h" @@ -112,7 +111,7 @@ std::wstring roundToBlock(double timeInHigh, const int blockSizeLow = granularity * timeInHigh < 1 ? numeric::nearMatch(granularity * timeInLow, std::begin(stepsLow), std::end(stepsLow)): numeric::nearMatch(granularity * timeInHigh, std::begin(stepsHigh), std::end(stepsHigh)) * unitLowPerHigh; - const int roundedtimeInLow = numeric::round(timeInLow / blockSizeLow) * blockSizeLow; + const int roundedtimeInLow = static_cast(numeric::round(timeInLow / blockSizeLow) * blockSizeLow); std::wstring output = formatUnitTime(roundedtimeInLow / unitLowPerHigh, unitHigh); if (unitLowPerHigh > blockSizeLow) @@ -162,13 +161,13 @@ std::wstring zen::formatFraction(double fraction) -std::wstring zen::ffs_Impl::includeNumberSeparator(const std::wstring& number) +std::wstring zen::impl::includeNumberSeparator(const std::wstring& number) { //we have to include thousands separator ourselves; this doesn't work for all countries (e.g india), but is better than nothing //::setlocale (LC_ALL, ""); -> implicitly called by wxLocale const lconv* localInfo = ::localeconv(); //always bound according to doc - const std::wstring& thousandSep = utfTo(localInfo->thousands_sep); + const std::wstring& thousandSep = zen::utfTo(localInfo->thousands_sep); // THOUSANDS_SEPARATOR = std::use_facet>(std::locale("")).thousands_sep(); - why not working? // DECIMAL_POINT = std::use_facet>(std::locale("")).decimal_point(); -- cgit