Verified Commit 08d2c7b3 authored by Fushan Wen's avatar Fushan Wen
Browse files

kcms/runners: Port away from `KPluginInfo::fromMetaData`

Deprecated since KF 5.90
parent c83c1af6
......@@ -25,13 +25,13 @@ KRunnerData::KRunnerData(QObject *parent, const QVariantList &args)
bool KRunnerData::isDefaults() const
{
QList<KPluginInfo> runnerInfos = KPluginInfo::fromMetaData(Plasma::RunnerManager::runnerMetaDataList());
const QVector<KPluginMetaData> runnerData = Plasma::RunnerManager::runnerMetaDataList();
KConfigGroup cfgGroup(m_krunnerConfig, "Plugins");
for (auto &plugin : runnerInfos) {
plugin.load(cfgGroup);
if (plugin.isPluginEnabled() != plugin.isPluginEnabledByDefault()) {
return false;
}
if (std::any_of(runnerData.cbegin(), runnerData.cend(), [&cfgGroup](const KPluginMetaData &pluginData) {
return pluginData.isEnabled(cfgGroup) != pluginData.isEnabledByDefault();
})) {
return false;
}
return m_settings->isDefaults();
......
Supports Markdown
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