Commit a5149896 authored by Nicolas Fella's avatar Nicolas Fella
Browse files

Port away from KMimeTypeTrader

It is about to be deprecated

See https://phabricator.kde.org/T12177
parent f3eb618f
...@@ -12,7 +12,7 @@ cmake_minimum_required (VERSION 3.5 FATAL_ERROR) ...@@ -12,7 +12,7 @@ cmake_minimum_required (VERSION 3.5 FATAL_ERROR)
project(Spectacle VERSION ${SPECTACLE_VERSION}) project(Spectacle VERSION ${SPECTACLE_VERSION})
set(QT_MIN_VERSION "5.10.0") set(QT_MIN_VERSION "5.10.0")
set(KF5_MIN_VERSION "5.56.0") set(KF5_MIN_VERSION "5.68.0")
find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE) find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE)
set( set(
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
#include "Config.h" #include "Config.h"
#include <KLocalizedString> #include <KLocalizedString>
#include <KMimeTypeTrader> #include <KApplicationTrader>
#include <KRun> #include <KRun>
#include <KStandardShortcut> #include <KStandardShortcut>
#ifdef KIPI_FOUND #ifdef KIPI_FOUND
...@@ -77,7 +77,7 @@ void ExportMenu::getKServiceItems() ...@@ -77,7 +77,7 @@ void ExportMenu::getKServiceItems()
// populate all locally installed applications and services // populate all locally installed applications and services
// which can handle images first // which can handle images first
const KService::List services = KMimeTypeTrader::self()->query(QStringLiteral("image/png")); const KService::List services = KApplicationTrader::queryByMimeType(QStringLiteral("image/png"));
for (auto service : services) { for (auto service : services) {
QString name = service->name().replace(QLatin1Char('&'), QLatin1String("&&")); QString name = service->name().replace(QLatin1Char('&'), QLatin1String("&&"));
......
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