X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Fqt%2FGuiChanges.cpp;h=b2f809b026a5bd9c620f339dd060552d09e551d7;hb=10f4f2113aa7ed45af7b6aca50e76d4bf9772732;hp=eda161d0d54fc67ee0c82e2cb249239d5ceb106f;hpb=26459a2cf5c434d8d7c0fa58b05770858776033f;p=lyx.git diff --git a/src/frontends/qt/GuiChanges.cpp b/src/frontends/qt/GuiChanges.cpp index eda161d0d5..b2f809b026 100644 --- a/src/frontends/qt/GuiChanges.cpp +++ b/src/frontends/qt/GuiChanges.cpp @@ -70,9 +70,15 @@ void GuiChanges::updateContents() text += inserted ? qt_("Inserted by %1").arg(author) : qt_("Deleted by %1").arg(author); +#if (QT_VERSION >= QT_VERSION_CHECK(5, 8, 0)) + QString const date = + QLocale().toString(QDateTime::fromSecsSinceEpoch(c.changetime), + QLocale::LongFormat); +#else QString const date = QLocale().toString(QDateTime::fromTime_t(c.changetime), QLocale::LongFormat); +#endif if (!date.isEmpty()) { if (!author.isEmpty()) text += qt_(" on[[date]] %1").arg(date);