Commit e99d6b08 authored by Bhushan Shah's avatar Bhushan Shah 📱

app: show all modules if runtime platform is not set

parent ddba6db1
Pipeline #5345 passed with stage
in 8 minutes and 13 seconds
...@@ -21,10 +21,14 @@ ModulesModel::ModulesModel(QObject* parent) ...@@ -21,10 +21,14 @@ ModulesModel::ModulesModel(QObject* parent)
package.setDefaultPackageRoot("kpackage/kcms"); package.setDefaultPackageRoot("kpackage/kcms");
package.setPath(pluginMetaData.pluginId()); package.setPath(pluginMetaData.pluginId());
bool isCurrentPlatform = false; bool isCurrentPlatform = false;
for (QString platform : KDeclarative::KDeclarative::runtimePlatform()) { if (KDeclarative::KDeclarative::runtimePlatform().isEmpty()) {
if (pluginMetaData.formFactors().contains(platform)) { isCurrentPlatform = true;
qDebug() << "Platform for " << pluginMetaData.name() << " is " << pluginMetaData.formFactors(); } else {
isCurrentPlatform = true; for (QString platform : KDeclarative::KDeclarative::runtimePlatform()) {
if (pluginMetaData.formFactors().contains(platform)) {
qDebug() << "Platform for " << pluginMetaData.name() << " is " << pluginMetaData.formFactors();
isCurrentPlatform = true;
}
} }
} }
if (isCurrentPlatform) { if (isCurrentPlatform) {
......
Markdown is supported
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