mirror of
https://invent.kde.org/frameworks/kimageformats.git
synced 2025-06-03 00:58:15 -04:00
Drop code for Qt < 6.5.0
...now that we depend on Qt >= 6.5.0.
This commit is contained in:
parent
adc7da4f41
commit
2799382c21
@ -54,9 +54,7 @@
|
|||||||
#include <QImage>
|
#include <QImage>
|
||||||
#include <QImageIOPlugin>
|
#include <QImageIOPlugin>
|
||||||
|
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0)
|
|
||||||
#include <QTimeZone>
|
#include <QTimeZone>
|
||||||
#endif
|
|
||||||
|
|
||||||
// Allow the code to works on all QT versions supported by KDE
|
// Allow the code to works on all QT versions supported by KDE
|
||||||
// project (Qt 5.15 and Qt 6.x) to easy backports fixes.
|
// project (Qt 5.15 and Qt 6.x) to easy backports fixes.
|
||||||
@ -194,11 +192,7 @@ bool EXRHandler::read(QImage *outImage)
|
|||||||
}
|
}
|
||||||
auto dateTime = QDateTime::fromString(QString::fromStdString(capDate->value()), QStringLiteral("yyyy:MM:dd HH:mm:ss"));
|
auto dateTime = QDateTime::fromString(QString::fromStdString(capDate->value()), QStringLiteral("yyyy:MM:dd HH:mm:ss"));
|
||||||
if (dateTime.isValid()) {
|
if (dateTime.isValid()) {
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0)
|
|
||||||
dateTime.setTimeZone(QTimeZone::fromSecondsAheadOfUtc(off));
|
dateTime.setTimeZone(QTimeZone::fromSecondsAheadOfUtc(off));
|
||||||
#else
|
|
||||||
dateTime.setOffsetFromUtc(off);
|
|
||||||
#endif
|
|
||||||
image.setText(QStringLiteral("Date"), dateTime.toString(Qt::ISODate));
|
image.setText(QStringLiteral("Date"), dateTime.toString(Qt::ISODate));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user