diff --git a/CMakeLists.txt b/CMakeLists.txt index ab624c0f..ca71715d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ project(plasma-phone-components) # minimal requirements cmake_minimum_required (VERSION 2.8.12 FATAL_ERROR) set (QT_MIN_VERSION "5.12.0") -set(KF5_MIN_VERSION "5.66.0") +set(KF5_MIN_VERSION "5.70.0") set(CMAKE_AUTOMOC ON) set(CMAKE_INCLUDE_CURRENT_DIR ON) @@ -33,6 +33,7 @@ find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS Plasma PlasmaQuick Service + Notifications ) find_package(KF5Wayland CONFIG) set_package_properties(KF5Wayland PROPERTIES diff --git a/containments/homescreen/CMakeLists.txt b/containments/homescreen/CMakeLists.txt index 4cb6f5ce..944cca6c 100644 --- a/containments/homescreen/CMakeLists.txt +++ b/containments/homescreen/CMakeLists.txt @@ -15,7 +15,8 @@ target_link_libraries(plasma_containment_phone_homescreen Qt5::Quick KF5::I18n KF5::Service - KF5::KIOWidgets + KF5::KIOGui + KF5::Notifications ) diff --git a/containments/homescreen/applicationlistmodel.cpp b/containments/homescreen/applicationlistmodel.cpp index 7b317178..6316558c 100644 --- a/containments/homescreen/applicationlistmodel.cpp +++ b/containments/homescreen/applicationlistmodel.cpp @@ -24,15 +24,16 @@ #include #include #include +#include // KDE +#include +#include #include #include #include #include #include -#include -#include constexpr int MAX_FAVOURITES = 5; @@ -325,8 +326,9 @@ void ApplicationListModel::runApplication(const QString &storageId) } KService::Ptr service = KService::serviceByStorageId(storageId); - - KRun::runService(*service, QList(), nullptr); + KIO::ApplicationLauncherJob *job = new KIO::ApplicationLauncherJob(service); + job->setUiDelegate(new KNotificationJobUiDelegate(KJobUiDelegate::AutoHandlingEnabled)); + job->start(); } int ApplicationListModel::maxFavoriteCount() const