MCPcopy Create free account
hub / github.com/KDE/kdevelop / PluginController

Method PluginController

kdevplatform/shell/plugincontroller.cpp:356–380  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

354};
355
356PluginController::PluginController(Core *core)
357 : IPluginController()
358 , d_ptr(new PluginControllerPrivate(core))
359{
360 Q_D(PluginController);
361
362 setObjectName(QStringLiteral("PluginController"));
363
364 d->plugins = KPluginMetaData::findPlugins(QStringLiteral("kdevplatform/" QT_STRINGIFY(KDEVELOP_PLUGIN_VERSION)));
365
366 qCDebug(SHELL) << "Found" << d->plugins.size() << "plugins:" << pluginIds(d->plugins);
367 if (d->plugins.empty()) {
368 qCWarning(SHELL) << "Did not find any plugins, check your environment.";
369 qCWarning(SHELL) << " Note: QT_PLUGIN_PATH is set to:" << qgetenv("QT_PLUGIN_PATH");
370 } else {
371 // KDevelop exits with an error if KDevelop plugins cannot be found. So do not
372 // waste time initializing KTextEditor integration then. Furthermore, finding
373 // KTextEditor plugins makes allPluginInfos() nonempty, which hinders error detection.
374 d->initKTextEditorIntegration();
375 }
376
377 d->cleanupMode = PluginControllerPrivate::Running;
378 // Register the KDevelop::IPlugin* metatype so we can properly unload it
379 qRegisterMetaType<KDevelop::IPlugin*>( "KDevelop::IPlugin*" );
380}
381
382PluginController::~PluginController()
383{

Callers

nothing calls this directly

Calls 4

pluginIdsFunction · 0.85
emptyMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected