Install KCMs in dolphin/kcms namespace

This will allow consumers to load the plugin from this namespace
without KServiceTypeTrader being involved.
This commit is contained in:
Alexander Lohnau 2021-09-02 20:11:11 +02:00
parent 1937681d50
commit 2f5e4cb029
No known key found for this signature in database
GPG key ID: 1F58708D54A003E7
7 changed files with 15 additions and 12 deletions

View file

@ -370,9 +370,12 @@ install(TARGETS dolphin ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
if(NOT WIN32)
# The settings are still accessible from the hamburger menu
add_library(kcm_dolphinviewmodes MODULE)
add_library(kcm_dolphinnavigation MODULE)
add_library(kcm_dolphingeneral MODULE)
add_library(kcm_dolphinviewmodes)
kcoreaddons_desktop_to_json(kcm_dolphinviewmodes settings/kcm/kcmdolphinviewmodes.desktop)
add_library(kcm_dolphinnavigation)
kcoreaddons_desktop_to_json(kcm_dolphinnavigation settings/kcm/kcmdolphinnavigation.desktop)
add_library(kcm_dolphingeneral)
kcoreaddons_desktop_to_json(kcm_dolphingeneral settings/kcm/kcmdolphingeneral.desktop)
target_sources(kcm_dolphinviewmodes PRIVATE
settings/kcm/kcmdolphinviewmodes.cpp
@ -420,9 +423,9 @@ if(NOT WIN32)
install( FILES settings/kcm/kcmdolphinnavigation.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR} )
install( FILES settings/kcm/kcmdolphingeneral.desktop DESTINATION ${KDE_INSTALL_KSERVICES5DIR} )
install(TARGETS kcm_dolphinviewmodes DESTINATION ${KDE_INSTALL_PLUGINDIR} )
install(TARGETS kcm_dolphinnavigation DESTINATION ${KDE_INSTALL_PLUGINDIR} )
install(TARGETS kcm_dolphingeneral DESTINATION ${KDE_INSTALL_PLUGINDIR} )
install(TARGETS kcm_dolphinviewmodes DESTINATION ${KDE_INSTALL_PLUGINDIR}/dolphin/kcms )
install(TARGETS kcm_dolphinnavigation DESTINATION ${KDE_INSTALL_PLUGINDIR}/dolphin/kcms )
install(TARGETS kcm_dolphingeneral DESTINATION ${KDE_INSTALL_PLUGINDIR}/dolphin/kcms )
endif()
if(NOT WIN32)

View file

@ -17,7 +17,7 @@
#include <QTabWidget>
#include <QVBoxLayout>
K_PLUGIN_FACTORY(KCMDolphinGeneralConfigFactory, registerPlugin<DolphinGeneralConfigModule>();)
K_PLUGIN_CLASS_WITH_JSON(DolphinGeneralConfigModule, "kcmdolphingeneral.json")
DolphinGeneralConfigModule::DolphinGeneralConfigModule(QWidget *parent, const QVariantList &args) :
KCModule(parent, args),

View file

@ -111,7 +111,7 @@ Icon=system-file-manager
Type=Service
X-KDE-ServiceTypes=KCModule
X-KDE-Library=kcm_dolphingeneral
X-KDE-Library=dolphin/kcms/kcm_dolphingeneral
X-DocPath=dolphin/configuring-dolphin.html#preferences-dialog
# ctxt: Random file browsing settings.
Name=General

View file

@ -13,7 +13,7 @@
#include <QVBoxLayout>
K_PLUGIN_FACTORY(KCMDolphinNavigationConfigFactory, registerPlugin<DolphinNavigationConfigModule>();)
K_PLUGIN_CLASS_WITH_JSON(DolphinNavigationConfigModule, "kcmdolphinnavigation.json")
DolphinNavigationConfigModule::DolphinNavigationConfigModule(QWidget *parent, const QVariantList &args) :
KCModule(parent, args),

View file

@ -111,7 +111,7 @@ Icon=preferences-desktop-navigation
Type=Service
X-KDE-ServiceTypes=KCModule
X-KDE-Library=kcm_dolphinnavigation
X-KDE-Library=dolphin/kcms/kcm_dolphinnavigation
X-DocPath=dolphin/configuring-dolphin.html#preferences-dialog-navigation
Name=Navigation
Name[ar]=التّنقّل

View file

@ -17,7 +17,7 @@
#include <QTabWidget>
#include <QVBoxLayout>
K_PLUGIN_FACTORY(KCMDolphinViewModesConfigFactory, registerPlugin<DolphinViewModesConfigModule>();)
K_PLUGIN_CLASS_WITH_JSON(DolphinViewModesConfigModule, "kcmdolphinviewmodes.json")
DolphinViewModesConfigModule::DolphinViewModesConfigModule(QWidget *parent, const QVariantList &args) :
KCModule(parent, args),

View file

@ -109,7 +109,7 @@ Icon=preferences-desktop-icons
Type=Service
X-KDE-ServiceTypes=KCModule
X-KDE-Library=kcm_dolphinviewmodes
X-KDE-Library=dolphin/kcms/kcm_dolphinviewmodes
X-DocPath=dolphin/configuring-dolphin.html#preferences-dialog-viewmodes
Name=View Modes
Name[ar]=أوضاع المنظور