Commit 5d1c3d77 authored by Laurent Montel's avatar Laurent Montel 😁

Make it compile against qt5.15. SkipEmptyParts is part of Qt::.

parent 1dcb9842
......@@ -74,7 +74,11 @@ int main(int argc, char *argv[])
}
if (parser.isSet(uidsOption)) {
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
const QStringList &uids = parser.value(uidsOption).split(QLatin1Char(','), QString::SkipEmptyParts);
#else
const QStringList &uids = parser.value(uidsOption).split(QLatin1Char(','), Qt::SkipEmptyParts);
#endif
if (!uids.isEmpty()) {
properties.insert(QStringLiteral("uids"), uids);
}
......
......@@ -397,7 +397,11 @@ void MimeTypeData::syncServices()
// Clean out any kde-mimeapps.list which would take precedence any cancel our changes.
const QString desktops = QString::fromLocal8Bit(qgetenv("XDG_CURRENT_DESKTOP"));
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
foreach (const QString &desktop, desktops.split(QLatin1Char(':'), QString::SkipEmptyParts)) {
#else
foreach (const QString &desktop, desktops.split(QLatin1Char(':'), Qt::SkipEmptyParts)) {
#endif
const QString file = QStandardPaths::writableLocation(QStandardPaths::GenericConfigLocation)
+ QLatin1Char('/') + desktop.toLower() + QLatin1String("-mimeapps.list");
if (QFileInfo::exists(file)) {
......
Markdown is supported
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