Emit deprecation warnings for loading KCM using a plugin keyword
Otherwise consumers will not know about the change and this way it is clear that the logic should be removed in the future
This commit is contained in:
parent
6f110bca1d
commit
cd4ef30b21
1 changed files with 5 additions and 0 deletions
|
@ -183,9 +183,14 @@ void PreviewBridge::configure(QQuickItem *ctx)
|
|||
|
||||
kcm = m_factory->create<KCModule>(dialog, QVariantList({args}));
|
||||
|
||||
#if KCOREADDONS_BUILD_DEPRECATED_SINCE(5, 87)
|
||||
if (!kcm) {
|
||||
kcm = m_factory->create<KCModule>(QStringLiteral("kcmodule"), dialog, QVariantList({args}));
|
||||
if (kcm) {
|
||||
qWarning() << "Loading a KCModule using the kcmodule keyword is deprecated in KWin 5.23, register the plugin without a keyword instead" << m_theme;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (!kcm) {
|
||||
return;
|
||||
|
|
Loading…
Reference in a new issue