diff options
| author | Alexander Lohnau <[email protected]> | 2023-02-15 07:45:11 +0100 |
|---|---|---|
| committer | Alexander Lohnau <[email protected]> | 2023-02-15 09:36:31 +0000 |
| commit | 54f62d22b06dc54979cc1a6e26ba881df5cc6ef1 (patch) | |
| tree | 361456d51603208430b1bc18b1ed5e3d05387430 /src/kitemviews/kfileitemmodelrolesupdater.cpp | |
| parent | 6b00c8b911ef0ea6a31caf7b0d2f405460d33e25 (diff) | |
Allow empty metadata for KOverlayIconPlugin
We do not read the metadata anywhere, consequently we can allow empty metadata.
Consumers now don't have to provide a file and we do no spend time parsing the JSON.
Task: https://phabricator.kde.org/T14538
Diffstat (limited to 'src/kitemviews/kfileitemmodelrolesupdater.cpp')
| -rw-r--r-- | src/kitemviews/kfileitemmodelrolesupdater.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/kitemviews/kfileitemmodelrolesupdater.cpp b/src/kitemviews/kfileitemmodelrolesupdater.cpp index 4fd126619..1a849dcd5 100644 --- a/src/kitemviews/kfileitemmodelrolesupdater.cpp +++ b/src/kitemviews/kfileitemmodelrolesupdater.cpp @@ -118,7 +118,8 @@ KFileItemModelRolesUpdater::KFileItemModelRolesUpdater(KFileItemModel *model, QO m_directoryContentsCounter = new KDirectoryContentsCounter(m_model, this); connect(m_directoryContentsCounter, &KDirectoryContentsCounter::result, this, &KFileItemModelRolesUpdater::slotDirectoryContentsCountReceived); - const auto plugins = KPluginMetaData::findPlugins(QStringLiteral("kf" QT_STRINGIFY(QT_VERSION_MAJOR)) + QStringLiteral("/overlayicon")); + const QString pluginNamespace = QStringLiteral("kf" QT_STRINGIFY(QT_VERSION_MAJOR)) + QStringLiteral("/overlayicon"); + const auto plugins = KPluginMetaData::findPlugins(pluginNamespace, {}, KPluginMetaData::AllowEmptyMetaData); for (const KPluginMetaData &data : plugins) { auto instance = QPluginLoader(data.fileName()).instance(); auto plugin = qobject_cast<KOverlayIconPlugin *>(instance); |
