Changeset View
Changeset View
Standalone View
Standalone View
kdevplatform/shell/settings/pluginpreferences.cpp
Show All 38 Lines | 38 | PluginPreferences::PluginPreferences(QWidget* parent) | |||
---|---|---|---|---|---|
39 | : ConfigPage(nullptr, nullptr, parent) | 39 | : ConfigPage(nullptr, nullptr, parent) | ||
40 | { | 40 | { | ||
41 | QVBoxLayout* lay = new QVBoxLayout(this ); | 41 | QVBoxLayout* lay = new QVBoxLayout(this ); | ||
42 | lay->setMargin(0); | 42 | lay->setMargin(0); | ||
43 | selector = new KPluginSelector( this ); | 43 | selector = new KPluginSelector( this ); | ||
44 | lay->addWidget( selector ); | 44 | lay->addWidget( selector ); | ||
45 | QMap<QString, QList<KPluginInfo>> plugins; | 45 | QMap<QString, QList<KPluginInfo>> plugins; | ||
46 | const QMap<QString, QString> categories = { | 46 | const QMap<QString, QString> categories = { | ||
47 | { "Core", i18nc("@title:group", "Core") }, | 47 | { QStringLiteral("Core"), i18nc("@title:group", "Core") }, | ||
48 | { "Project Management", i18nc("@title:group", "Project Management") }, | 48 | { QStringLiteral("Project Management"), i18nc("@title:group", "Project Management") }, | ||
49 | { "Version Control", i18nc("@title:group", "Version Control") }, | 49 | { QStringLiteral("Version Control"), i18nc("@title:group", "Version Control") }, | ||
50 | { "Utilities", i18nc("@title:group", "Utilities") }, | 50 | { QStringLiteral("Utilities"), i18nc("@title:group", "Utilities") }, | ||
51 | { "Documentation", i18nc("@title:group", "Documentation") }, | 51 | { QStringLiteral("Documentation"), i18nc("@title:group", "Documentation") }, | ||
52 | { "Language Support", i18nc("@title:group", "Language Support") }, | 52 | { QStringLiteral("Language Support"), i18nc("@title:group", "Language Support") }, | ||
53 | { "Debugging", i18nc("@title:group", "Debugging") }, | 53 | { QStringLiteral("Debugging"), i18nc("@title:group", "Debugging") }, | ||
54 | { "Testing", i18nc("@title:group", "Testing") }, | 54 | { QStringLiteral("Testing"), i18nc("@title:group", "Testing") }, | ||
55 | { "Analyzers", i18nc("@title:group", "Analyzers") }, | 55 | { QStringLiteral("Analyzers"), i18nc("@title:group", "Analyzers") }, | ||
56 | { "Runtimes", i18nc("@title:group", "Runtimes") }, | 56 | { QStringLiteral("Runtimes"), i18nc("@title:group", "Runtimes") }, | ||
57 | { "Other", i18nc("@title:group", "Other") } | 57 | { QStringLiteral("Other"), i18nc("@title:group", "Other") } | ||
58 | }; | 58 | }; | ||
59 | foreach (const KPluginMetaData& info, Core::self()->pluginControllerInternal()->allPluginInfos()) { | 59 | foreach (const KPluginMetaData& info, Core::self()->pluginControllerInternal()->allPluginInfos()) { | ||
60 | const QString loadMode = info.value(QStringLiteral("X-KDevelop-LoadMode")); | 60 | const QString loadMode = info.value(QStringLiteral("X-KDevelop-LoadMode")); | ||
61 | if( loadMode.isEmpty() || loadMode == QLatin1String("UserSelectable") ) | 61 | if( loadMode.isEmpty() || loadMode == QLatin1String("UserSelectable") ) | ||
62 | { | 62 | { | ||
63 | QString category = info.category(); | 63 | QString category = info.category(); | ||
64 | if (!categories.contains(category)) { | 64 | if (!categories.contains(category)) { | ||
65 | if (!category.isEmpty()) { | 65 | if (!category.isEmpty()) { | ||
▲ Show 20 Lines • Show All 43 Lines • Show Last 20 Lines |