diff --git a/src/plugins/overview/CMakeLists.txt b/src/plugins/overview/CMakeLists.txt index 2c8f5d4054..d57b3ee610 100644 --- a/src/plugins/overview/CMakeLists.txt +++ b/src/plugins/overview/CMakeLists.txt @@ -16,6 +16,17 @@ kconfig_add_kcfg_files(overview_SOURCES ) kwin_add_builtin_effect(overview ${overview_SOURCES}) + +qt6_add_qml_module(overview + NO_PLUGIN + URI overview + RESOURCE_PREFIX / + QML_FILES + qml/DesktopBar.qml + qml/DesktopView.qml + qml/main.qml +) + target_link_libraries(overview PRIVATE kwineffects @@ -25,5 +36,3 @@ target_link_libraries(overview PRIVATE Qt::Quick ) - -install(DIRECTORY qml DESTINATION ${KDE_INSTALL_DATADIR}/kwin/effects/overview) diff --git a/src/plugins/overview/overvieweffect.cpp b/src/plugins/overview/overvieweffect.cpp index b3072133db..98087f6f6a 100644 --- a/src/plugins/overview/overvieweffect.cpp +++ b/src/plugins/overview/overvieweffect.cpp @@ -54,7 +54,7 @@ OverviewEffect::OverviewEffect() initConfig(); reconfigure(ReconfigureAll); - setSource(QUrl::fromLocalFile(QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kwin/effects/overview/qml/main.qml")))); + setSource(QUrl(QStringLiteral("qrc:/overview/qml/main.qml"))); } OverviewEffect::~OverviewEffect()