1
0
mirror of https://github.com/QtExcel/QXlsx.git synced 2025-01-30 05:02:52 +08:00

Revert std::lround usage

FIXES #381
This commit is contained in:
Daniel Nicoletti 2025-01-22 10:35:16 -03:00
parent 9e4ebc0396
commit 4f188ed320

View File

@ -90,7 +90,7 @@ QVariant datetimeFromNumber(double num, bool is1904)
num = num - 1; num = num - 1;
} }
auto msecs = static_cast<qint64>(std::lround(num * 1000 * 60 * 60 * 24.0)); auto msecs = static_cast<qint64>(num * 1000 * 60 * 60 * 24.0 + 0.5);
if (is1904) if (is1904)
msecs += msecs1904; msecs += msecs1904;