Commit b5882245 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Port to QMetaType

parent 1a106aae
Pipeline #180665 passed with stage
in 2 minutes and 29 seconds
......@@ -50,15 +50,22 @@ public:
}
protected:
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
QVariant retrieveData(const QString &format, QVariant::Type type) const override
#else
QVariant retrieveData(const QString &format, QMetaType type) const override
#endif
{
if (!m_source) {
return QVariant();
}
// Doesn't work, is protected:
// return m_source->retrieveData( format, type );
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
switch (type) {
#else
switch (type.id()) {
#endif
case QVariant::String:
if (format == QLatin1String("text/plain")) {
return m_source->text();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment