forked from qt-creator/qt-creator
Use simpler Plugin::initialize() when feasible
Change-Id: I567965d266f20526bda9f823e31a04b354d53fb1 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -31,7 +31,6 @@ public:
|
||||
~IPlugin() override;
|
||||
|
||||
virtual bool initialize(const QStringList &arguments, QString *errorString);
|
||||
virtual void initialize() {}
|
||||
virtual void extensionsInitialized() {}
|
||||
virtual bool delayedInitialize() { return false; }
|
||||
virtual ShutdownFlag aboutToShutdown() { return SynchronousShutdown; }
|
||||
@@ -42,6 +41,9 @@ public:
|
||||
|
||||
PluginSpec *pluginSpec() const;
|
||||
|
||||
protected:
|
||||
virtual void initialize() {}
|
||||
|
||||
signals:
|
||||
void asynchronousShutdownFinished();
|
||||
|
||||
|
@@ -121,11 +121,8 @@ AndroidPlugin::~AndroidPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool AndroidPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void AndroidPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new AndroidPluginPrivate;
|
||||
|
||||
connect(KitManager::instance(), &KitManager::kitsLoaded,
|
||||
@@ -135,7 +132,6 @@ bool AndroidPlugin::initialize(const QStringList &arguments, QString *errorMessa
|
||||
{Android::Constants::JLS_SETTINGS_ID,
|
||||
Tr::tr("Java Language Server"),
|
||||
[] { return new JLSSettings; }});
|
||||
return true;
|
||||
}
|
||||
|
||||
void AndroidPlugin::kitsRestored()
|
||||
|
@@ -15,7 +15,7 @@ class AndroidPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~AndroidPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
void kitsRestored();
|
||||
void askUserAboutAndroidSetup();
|
||||
|
@@ -276,17 +276,13 @@ void AutotestPluginPrivate::initializeMenuEntries()
|
||||
this, &AutotestPlugin::updateMenuItemsEnabledState);
|
||||
}
|
||||
|
||||
bool AutotestPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void AutotestPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
dd = new AutotestPluginPrivate;
|
||||
#ifdef WITH_TESTS
|
||||
ExtensionSystem::PluginManager::registerScenario("TestModelManagerInterface",
|
||||
[] { return dd->m_loadProjectScenario(); });
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
void AutotestPlugin::extensionsInitialized()
|
||||
|
@@ -39,7 +39,7 @@ public:
|
||||
AutotestPlugin();
|
||||
~AutotestPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
|
||||
|
@@ -63,15 +63,10 @@ AutotoolsProjectPlugin::~AutotoolsProjectPlugin()
|
||||
void AutotoolsProjectPlugin::extensionsInitialized()
|
||||
{ }
|
||||
|
||||
bool AutotoolsProjectPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void AutotoolsProjectPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new AutotoolsProjectPluginPrivate;
|
||||
ProjectExplorer::ProjectManager::registerProjectType<AutotoolsProject>(Constants::MAKEFILE_MIMETYPE);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // AutotoolsProjectManager::Internal
|
||||
|
@@ -43,7 +43,7 @@ class AutotoolsProjectPlugin final : public ExtensionSystem::IPlugin
|
||||
~AutotoolsProjectPlugin() final;
|
||||
|
||||
void extensionsInitialized() final;
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
class AutotoolsProjectPluginPrivate *d;
|
||||
};
|
||||
|
@@ -66,13 +66,9 @@ BareMetalPlugin::~BareMetalPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool BareMetalPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void BareMetalPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new BareMetalPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
void BareMetalPlugin::extensionsInitialized()
|
||||
|
@@ -15,7 +15,7 @@ class BareMetalPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~BareMetalPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
class BareMetalPluginPrivate *d = nullptr;
|
||||
|
@@ -334,12 +334,9 @@ BazaarPlugin::~BazaarPlugin()
|
||||
d = nullptr;
|
||||
}
|
||||
|
||||
bool BazaarPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void BazaarPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
d = new BazaarPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
void BazaarPlugin::extensionsInitialized()
|
||||
|
@@ -14,7 +14,7 @@ class BazaarPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~BazaarPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
#ifdef WITH_TESTS
|
||||
|
@@ -91,16 +91,12 @@ public:
|
||||
|
||||
static BeautifierPluginPrivate *dd = nullptr;
|
||||
|
||||
bool BeautifierPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void BeautifierPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
Core::ActionContainer *menu = Core::ActionManager::createMenu(Constants::MENU_ID);
|
||||
menu->menu()->setTitle(Tr::tr("Bea&utifier"));
|
||||
menu->setOnAllDisabledBehavior(Core::ActionContainer::Show);
|
||||
Core::ActionManager::actionContainer(Core::Constants::M_TOOLS)->addMenu(menu);
|
||||
return true;
|
||||
}
|
||||
|
||||
void BeautifierPlugin::extensionsInitialized()
|
||||
|
@@ -24,7 +24,7 @@ public:
|
||||
static void showError(const QString &error);
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
};
|
||||
|
@@ -502,14 +502,9 @@ BinEditorPlugin::~BinEditorPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool BinEditorPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void BinEditorPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
dd = new BinEditorPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // BinEditor::Internal
|
||||
|
@@ -16,7 +16,7 @@ class BinEditorPlugin : public ExtensionSystem::IPlugin
|
||||
|
||||
~BinEditorPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final {}
|
||||
};
|
||||
|
||||
|
@@ -67,10 +67,9 @@ BookmarksPlugin::~BookmarksPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool BookmarksPlugin::initialize(const QStringList &, QString *)
|
||||
void BookmarksPlugin::initialize()
|
||||
{
|
||||
d = new BookmarksPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
BookmarksPluginPrivate::BookmarksPluginPrivate()
|
||||
|
@@ -14,7 +14,7 @@ class BookmarksPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~BookmarksPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
class BookmarksPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -164,16 +164,11 @@ QdbPlugin::~QdbPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool QdbPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void QdbPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new QdbPluginPrivate;
|
||||
|
||||
registerFlashAction(this);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void QdbPlugin::extensionsInitialized()
|
||||
|
@@ -17,7 +17,7 @@ public:
|
||||
~QdbPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
ShutdownFlag aboutToShutdown() final;
|
||||
|
||||
|
@@ -76,11 +76,8 @@ ClangCodeModelPlugin::~ClangCodeModelPlugin()
|
||||
m_generatorWatcher.waitForFinished();
|
||||
}
|
||||
|
||||
bool ClangCodeModelPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void ClangCodeModelPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
TaskHub::addCategory(Constants::TASK_CATEGORY_DIAGNOSTICS,
|
||||
Tr::tr("Clang Code Model"));
|
||||
|
||||
@@ -93,8 +90,6 @@ bool ClangCodeModelPlugin::initialize(const QStringList &arguments, QString *err
|
||||
std::make_unique<ClangModelManagerSupport>());
|
||||
|
||||
createCompilationDBAction();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void ClangCodeModelPlugin::createCompilationDBAction()
|
||||
|
@@ -21,12 +21,11 @@ class ClangCodeModelPlugin final: public ExtensionSystem::IPlugin
|
||||
|
||||
public:
|
||||
~ClangCodeModelPlugin() override;
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) override;
|
||||
void initialize() override;
|
||||
|
||||
private:
|
||||
void maybeHandleBatchFileAndExit() const;
|
||||
|
||||
private:
|
||||
void generateCompilationDB();
|
||||
void createCompilationDBAction();
|
||||
|
||||
|
@@ -87,10 +87,8 @@ static void replaceCppCodeStyle()
|
||||
TextEditorSettings::registerCodeStyleFactory(new ClangFormatStyleFactory);
|
||||
}
|
||||
|
||||
bool ClangFormatPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void ClangFormatPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
replaceCppCodeStyle();
|
||||
|
||||
ActionContainer *contextMenu = ActionManager::actionContainer(CppEditor::Constants::M_CONTEXT);
|
||||
@@ -127,7 +125,6 @@ bool ClangFormatPlugin::initialize(const QStringList &arguments, QString *errorS
|
||||
openClangFormatConfigAction->setData(doc->filePath().toVariant());
|
||||
});
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
QVector<QObject *> ClangFormatPlugin::createTestObjects() const
|
||||
|
@@ -12,7 +12,7 @@ class ClangFormatPlugin : public ExtensionSystem::IPlugin
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QtCreatorPlugin" FILE "ClangFormat.json")
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
QVector<QObject *> createTestObjects() const override;
|
||||
};
|
||||
|
||||
|
@@ -88,11 +88,8 @@ ClangToolsPlugin::~ClangToolsPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool ClangToolsPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void ClangToolsPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
TaskHub::addCategory(taskCategory(), Tr::tr("Clang Tools"));
|
||||
|
||||
// Import tidy/clazy diagnostic configs from CppEditor now
|
||||
@@ -115,8 +112,6 @@ bool ClangToolsPlugin::initialize(const QStringList &arguments, QString *errorSt
|
||||
&Core::EditorManager::currentEditorChanged,
|
||||
this,
|
||||
&ClangToolsPlugin::onCurrentEditorChanged);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void ClangToolsPlugin::onCurrentEditorChanged()
|
||||
|
@@ -23,7 +23,7 @@ public:
|
||||
~ClangToolsPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
void registerAnalyzeActions();
|
||||
void onCurrentEditorChanged();
|
||||
|
||||
|
@@ -34,14 +34,9 @@ ClassViewPlugin::~ClassViewPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool ClassViewPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void ClassViewPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
dd = new ClassViewPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
|
@@ -18,7 +18,7 @@ public:
|
||||
~ClassViewPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage = nullptr) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final {}
|
||||
};
|
||||
|
||||
|
@@ -560,11 +560,9 @@ QString ClearCasePluginPrivate::findTopLevel(const FilePath &directory) const
|
||||
return ccManagesDirectory(directory);
|
||||
}
|
||||
|
||||
bool ClearCasePlugin::initialize(const QStringList & /*arguments */, QString *errorMessage)
|
||||
void ClearCasePlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
dd = new ClearCasePluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
void ClearCasePlugin::extensionsInitialized()
|
||||
|
@@ -67,7 +67,7 @@ public:
|
||||
static QSharedPointer<StatusMap> statusMap();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *error_message) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
#ifdef WITH_TESTS
|
||||
|
@@ -149,10 +149,8 @@ CMakeProjectPlugin::~CMakeProjectPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool CMakeProjectPlugin::initialize(const QStringList & /*arguments*/, QString *errorMessage)
|
||||
void CMakeProjectPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new CMakeProjectPluginPrivate;
|
||||
projectTypeSpecificSettings()->readSettings(ICore::settings());
|
||||
|
||||
@@ -195,8 +193,6 @@ bool CMakeProjectPlugin::initialize(const QStringList & /*arguments*/, QString *
|
||||
|
||||
d->cmakeFormatter.initialize();
|
||||
d->updateActions();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void CMakeProjectPlugin::extensionsInitialized()
|
||||
|
@@ -36,7 +36,7 @@ private slots:
|
||||
#endif
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
void updateContextActions(ProjectExplorer::Node *node);
|
||||
|
@@ -86,7 +86,7 @@ CocoPlugin::~CocoPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool CocoPlugin::initialize(const QStringList &, QString *)
|
||||
void CocoPlugin::initialize()
|
||||
{
|
||||
using namespace Core;
|
||||
ActionContainer *menu = ActionManager::actionContainer(Debugger::Constants::M_DEBUG_ANALYZER);
|
||||
@@ -97,7 +97,6 @@ bool CocoPlugin::initialize(const QStringList &, QString *)
|
||||
|
||||
connect(startCoco, &QAction::triggered, this, [this]() { d->startCoco(); });
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace Coco
|
||||
|
@@ -18,7 +18,7 @@ public:
|
||||
CocoPlugin();
|
||||
~CocoPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
private:
|
||||
CocoPluginPrivate *d;
|
||||
};
|
||||
|
@@ -42,11 +42,8 @@ CompilationDatabaseProjectManagerPlugin::~CompilationDatabaseProjectManagerPlugi
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool CompilationDatabaseProjectManagerPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void CompilationDatabaseProjectManagerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new CompilationDatabaseProjectManagerPluginPrivate;
|
||||
|
||||
Utils::FileIconProvider::registerIconOverlayForFilename(Utils::Icons::PROJECT.imageFilePath().toString(),
|
||||
@@ -80,8 +77,6 @@ bool CompilationDatabaseProjectManagerPlugin::initialize(const QStringList &argu
|
||||
|
||||
connect(ProjectTree::instance(), &ProjectTree::currentProjectChanged,
|
||||
this, onProjectChanged);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
QVector<QObject *> CompilationDatabaseProjectManagerPlugin::createTestObjects() const
|
||||
|
@@ -15,7 +15,7 @@ class CompilationDatabaseProjectManagerPlugin final : public ExtensionSystem::IP
|
||||
|
||||
~CompilationDatabaseProjectManagerPlugin();
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
QVector<QObject *> createTestObjects() const final;
|
||||
|
||||
class CompilationDatabaseProjectManagerPluginPrivate *d = nullptr;
|
||||
|
@@ -34,21 +34,13 @@ ConanPlugin::~ConanPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
void ConanPlugin::extensionsInitialized()
|
||||
{ }
|
||||
|
||||
bool ConanPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void ConanPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new ConanPluginPrivate;
|
||||
conanSettings()->readSettings(ICore::settings());
|
||||
|
||||
connect(SessionManager::instance(), &SessionManager::projectAdded,
|
||||
this, &ConanPlugin::projectAdded);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static void connectTarget(Project *project, Target *target)
|
||||
|
@@ -26,8 +26,7 @@ private:
|
||||
~ConanPlugin() final;
|
||||
void projectAdded(ProjectExplorer::Project *project);
|
||||
|
||||
void extensionsInitialized() final;
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
class ConanPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -44,7 +44,7 @@
|
||||
To make your wizard known to the system, add your IWizardFactory instance to the
|
||||
plugin manager's object pool in your plugin's initialize function:
|
||||
\code
|
||||
bool MyPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void MyPlugin::initialize()
|
||||
{
|
||||
// ... do setup
|
||||
addAutoReleasedObject(new MyWizardFactory);
|
||||
|
@@ -116,14 +116,9 @@ CodePasterPlugin::~CodePasterPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool CodePasterPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void CodePasterPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new CodePasterPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
CodePasterPluginPrivate::CodePasterPluginPrivate()
|
||||
|
@@ -43,7 +43,7 @@ public:
|
||||
~CodePasterPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
ShutdownFlag aboutToShutdown() final;
|
||||
|
||||
CodePasterPluginPrivate *d = nullptr;
|
||||
|
@@ -133,11 +133,8 @@ CppcheckPlugin::CppcheckPlugin() = default;
|
||||
|
||||
CppcheckPlugin::~CppcheckPlugin() = default;
|
||||
|
||||
bool CppcheckPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void CppcheckPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d.reset(new CppcheckPluginPrivate);
|
||||
|
||||
using namespace Core;
|
||||
@@ -156,8 +153,6 @@ bool CppcheckPlugin::initialize(const QStringList &arguments, QString *errorStri
|
||||
connect(ProjectExplorerPlugin::instance(), &ProjectExplorerPlugin::runActionsUpdated,
|
||||
d.get(), &CppcheckPluginPrivate::updateManualRunAction);
|
||||
d->updateManualRunAction();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Cppcheck::Internal
|
||||
|
@@ -21,7 +21,7 @@ public:
|
||||
~CppcheckPlugin() override;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
std::unique_ptr<CppcheckPluginPrivate> d;
|
||||
};
|
||||
|
@@ -224,10 +224,8 @@ CppQuickFixAssistProvider *CppEditorPlugin::quickFixProvider() const
|
||||
return &d->m_quickFixProvider;
|
||||
}
|
||||
|
||||
bool CppEditorPlugin::initialize(const QStringList & /*arguments*/, QString *errorMessage)
|
||||
void CppEditorPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new CppEditorPluginPrivate;
|
||||
d->initialize();
|
||||
|
||||
@@ -465,8 +463,6 @@ bool CppEditorPlugin::initialize(const QStringList & /*arguments*/, QString *err
|
||||
d, &CppEditorPluginPrivate::onTaskStarted);
|
||||
connect(ProgressManager::instance(), &ProgressManager::allTasksFinished,
|
||||
d, &CppEditorPluginPrivate::onAllTasksFinished);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void CppEditorPlugin::extensionsInitialized()
|
||||
|
@@ -53,7 +53,7 @@ signals:
|
||||
void includeHierarchyRequested();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
QVector<QObject *> createTestObjects() const override;
|
||||
|
||||
|
@@ -1,5 +1,6 @@
|
||||
// Copyright (C) 2019 Klarälvdalens Datakonsult AB, a KDAB Group company,
|
||||
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
||||
|
||||
#include "ctfvisualizerplugin.h"
|
||||
|
||||
#include "ctfvisualizertool.h"
|
||||
@@ -18,13 +19,9 @@ CtfVisualizerPlugin::~CtfVisualizerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool CtfVisualizerPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void CtfVisualizerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new CtfVisualizerPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
|
@@ -16,7 +16,7 @@ class CtfVisualizerPlugin : public ExtensionSystem::IPlugin
|
||||
public:
|
||||
~CtfVisualizerPlugin();
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
class CtfVisualizerPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -480,12 +480,9 @@ CvsPlugin::~CvsPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool CvsPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void CvsPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
dd = new CvsPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
void CvsPlugin::extensionsInitialized()
|
||||
|
@@ -14,7 +14,7 @@ class CvsPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~CvsPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
#ifdef WITH_TESTS
|
||||
|
@@ -57,10 +57,8 @@ FormEditorPlugin::~FormEditorPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool FormEditorPlugin::initialize(const QStringList &arguments, QString *error)
|
||||
void FormEditorPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
|
||||
d = new FormEditorPluginPrivate;
|
||||
|
||||
#ifdef CPP_ENABLED
|
||||
@@ -91,8 +89,6 @@ bool FormEditorPlugin::initialize(const QStringList &arguments, QString *error)
|
||||
if (qtr->load(trFile, qtTrPath) || qtr->load(trFile, creatorTrPath))
|
||||
QCoreApplication::installTranslator(qtr);
|
||||
}
|
||||
error->clear();
|
||||
return true;
|
||||
}
|
||||
|
||||
void FormEditorPlugin::extensionsInitialized()
|
||||
|
@@ -24,7 +24,7 @@ private slots:
|
||||
#endif
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage = nullptr) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
|
||||
void switchSourceForm();
|
||||
|
@@ -524,14 +524,9 @@ DiffEditorPlugin::~DiffEditorPlugin()
|
||||
s_instance = nullptr;
|
||||
}
|
||||
|
||||
bool DiffEditorPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void DiffEditorPlugin::initialize()
|
||||
{
|
||||
d = new DiffEditorPluginPrivate;
|
||||
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
FutureSynchronizer *DiffEditorPlugin::futureSynchronizer()
|
||||
|
@@ -32,7 +32,7 @@ public:
|
||||
DiffEditorPlugin();
|
||||
~DiffEditorPlugin();
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
static Utils::FutureSynchronizer *futureSynchronizer();
|
||||
|
||||
|
@@ -53,14 +53,9 @@ DockerPlugin::~DockerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool DockerPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void DockerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new DockerPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Docker::Interanl
|
||||
|
@@ -24,7 +24,7 @@ public:
|
||||
private:
|
||||
~DockerPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
class DockerPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -69,11 +69,8 @@ EmacsKeysPlugin::EmacsKeysPlugin() = default;
|
||||
|
||||
EmacsKeysPlugin::~EmacsKeysPlugin() = default;
|
||||
|
||||
bool EmacsKeysPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void EmacsKeysPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
// We have to use this hack here at the moment, because it's the only way to
|
||||
// disable Qt Creator menu accelerators aka mnemonics. Many of them get into
|
||||
// the way of typical emacs keys, such as: Alt+F (File), Alt+B (Build),
|
||||
@@ -130,7 +127,6 @@ bool EmacsKeysPlugin::initialize(const QStringList &arguments, QString *errorStr
|
||||
&EmacsKeysPlugin::scrollHalfDown, tr("Scroll Half Screen Down"));
|
||||
registerAction(Constants::SCROLL_HALF_UP,
|
||||
&EmacsKeysPlugin::scrollHalfUp, tr("Scroll Half Screen Up"));
|
||||
return true;
|
||||
}
|
||||
|
||||
void EmacsKeysPlugin::extensionsInitialized()
|
||||
|
@@ -55,7 +55,7 @@ public:
|
||||
EmacsKeysPlugin();
|
||||
~EmacsKeysPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
|
||||
|
@@ -499,7 +499,7 @@ class FakeVimPluginPrivate : public QObject
|
||||
public:
|
||||
FakeVimPluginPrivate();
|
||||
|
||||
bool initialize();
|
||||
void initialize();
|
||||
|
||||
void editorOpened(Core::IEditor *);
|
||||
void editorAboutToClose(Core::IEditor *);
|
||||
@@ -1155,7 +1155,7 @@ FakeVimPluginPrivate::FakeVimPluginPrivate()
|
||||
}
|
||||
}
|
||||
|
||||
bool FakeVimPluginPrivate::initialize()
|
||||
void FakeVimPluginPrivate::initialize()
|
||||
{
|
||||
runData = new FakeVimPluginRunData;
|
||||
/*
|
||||
@@ -1230,8 +1230,6 @@ bool FakeVimPluginPrivate::initialize()
|
||||
this, &FakeVimPluginPrivate::handleDelayedQuitAll, Qt::QueuedConnection);
|
||||
|
||||
setCursorBlinking(s.blinkingCursor.value());
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void FakeVimPluginPrivate::userActionTriggered(int key)
|
||||
@@ -2138,11 +2136,9 @@ FakeVimPlugin::~FakeVimPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool FakeVimPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void FakeVimPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
return dd->initialize();
|
||||
dd->initialize();
|
||||
}
|
||||
|
||||
ExtensionSystem::IPlugin::ShutdownFlag FakeVimPlugin::aboutToShutdown()
|
||||
|
@@ -21,7 +21,7 @@ public:
|
||||
|
||||
private:
|
||||
// implementation of ExtensionSystem::IPlugin
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) override;
|
||||
void initialize() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
void extensionsInitialized() override;
|
||||
|
||||
|
@@ -54,10 +54,9 @@ GenericProjectPlugin::~GenericProjectPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool GenericProjectPlugin::initialize(const QStringList &, QString *)
|
||||
void GenericProjectPlugin::initialize()
|
||||
{
|
||||
d = new GenericProjectPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
GenericProjectPluginPrivate::GenericProjectPluginPrivate()
|
||||
|
@@ -17,7 +17,7 @@ public:
|
||||
~GenericProjectPlugin() override;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override { }
|
||||
|
||||
class GenericProjectPluginPrivate *d = nullptr;
|
||||
|
@@ -67,7 +67,7 @@ GitLabPlugin::~GitLabPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool GitLabPlugin::initialize(const QStringList & /*arguments*/, QString * /*errorString*/)
|
||||
void GitLabPlugin::initialize()
|
||||
{
|
||||
dd = new GitLabPluginPrivate;
|
||||
dd->parameters.fromSettings(Core::ICore::settings());
|
||||
@@ -91,7 +91,6 @@ bool GitLabPlugin::initialize(const QStringList & /*arguments*/, QString * /*err
|
||||
connect(ProjectExplorer::SessionManager::instance(),
|
||||
&ProjectExplorer::SessionManager::startupProjectChanged,
|
||||
this, &GitLabPlugin::onStartupProjectChanged);
|
||||
return true;
|
||||
}
|
||||
|
||||
void GitLabPlugin::openView()
|
||||
|
@@ -24,7 +24,7 @@ public:
|
||||
GitLabPlugin();
|
||||
~GitLabPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
|
||||
static QList<GitLabServer> allGitLabServers();
|
||||
static GitLabServer gitLabServerForId(const Utils::Id &id);
|
||||
|
@@ -92,7 +92,7 @@ GlslEditorPlugin::~GlslEditorPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool GlslEditorPlugin::initialize(const QStringList &, QString *)
|
||||
void GlslEditorPlugin::initialize()
|
||||
{
|
||||
dd = new GlslEditorPluginPrivate;
|
||||
|
||||
@@ -111,8 +111,6 @@ bool GlslEditorPlugin::initialize(const QStringList &, QString *)
|
||||
|
||||
Command *cmd = ActionManager::command(TextEditor::Constants::UN_COMMENT_SELECTION);
|
||||
contextMenu->addAction(cmd);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void GlslEditorPlugin::extensionsInitialized()
|
||||
|
@@ -40,7 +40,7 @@ public:
|
||||
static const InitFile *shaderInit(int variant);
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
};
|
||||
|
||||
|
@@ -158,12 +158,9 @@ void HelpPlugin::showHelpUrl(const QUrl &url, Core::HelpManager::HelpViewerLocat
|
||||
dd->showHelpUrl(url, location);
|
||||
}
|
||||
|
||||
bool HelpPlugin::initialize(const QStringList &arguments, QString *error)
|
||||
void HelpPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(error)
|
||||
dd = new HelpPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
HelpPluginPrivate::HelpPluginPrivate()
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
static HelpWidget *modeHelpWidget();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
bool delayedInitialize() final;
|
||||
ShutdownFlag aboutToShutdown() final;
|
||||
|
@@ -114,14 +114,9 @@ ImageViewerPlugin::~ImageViewerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool ImageViewerPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void ImageViewerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new ImageViewerPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // ImageViewer::Internal
|
||||
|
@@ -18,7 +18,7 @@ public:
|
||||
~ImageViewerPlugin();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
class ImageViewerPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -20,14 +20,9 @@ IncrediBuildPlugin::~IncrediBuildPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool IncrediBuildPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void IncrediBuildPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new IncrediBuildPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // IncrediBuild::Internal
|
||||
|
@@ -16,7 +16,7 @@ public:
|
||||
IncrediBuildPlugin() = default;
|
||||
~IncrediBuildPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
|
||||
private:
|
||||
class IncrediBuildPluginPrivate *d = nullptr;
|
||||
|
@@ -67,18 +67,13 @@ IosPlugin::~IosPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool IosPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void IosPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
qRegisterMetaType<Ios::IosToolHandler::Dict>("Ios::IosToolHandler::Dict");
|
||||
|
||||
IosConfigurations::initialize();
|
||||
|
||||
d = new IosPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
} // Internal::Ios
|
||||
|
@@ -17,7 +17,7 @@ public:
|
||||
~IosPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
class IosPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -33,7 +33,7 @@ LanguageClientPlugin *LanguageClientPlugin::instance()
|
||||
return m_instance;
|
||||
}
|
||||
|
||||
bool LanguageClientPlugin::initialize(const QStringList & /*arguments*/, QString * /*errorString*/)
|
||||
void LanguageClientPlugin::initialize()
|
||||
{
|
||||
using namespace Core;
|
||||
|
||||
@@ -50,8 +50,6 @@ bool LanguageClientPlugin::initialize(const QStringList & /*arguments*/, QString
|
||||
connect(inspectAction, &QAction::triggered, this, &LanguageClientManager::showInspector);
|
||||
toolsDebugContainer->addAction(
|
||||
ActionManager::registerAction(inspectAction, "LanguageClient.InspectLanguageClients"));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void LanguageClientPlugin::extensionsInitialized()
|
||||
|
@@ -22,7 +22,7 @@ public:
|
||||
|
||||
// IPlugin interface
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
|
||||
|
@@ -38,11 +38,8 @@ MacrosPlugin::~MacrosPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool MacrosPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void MacrosPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new MacrosPluginPrivate;
|
||||
|
||||
Core::Context textContext(TextEditor::Constants::C_TEXTEDITOR);
|
||||
@@ -79,10 +76,7 @@ bool MacrosPlugin::initialize(const QStringList &arguments, QString *errorMessag
|
||||
command = Core::ActionManager::registerAction(saveLastMacro, Constants::SAVE_LAST_MACRO, textContext);
|
||||
mmacrotools->addAction(command);
|
||||
connect(saveLastMacro, &QAction::triggered, &d->macroManager, &MacroManager::saveLastMacro);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
} // Internal
|
||||
} // Macros
|
||||
|
@@ -16,7 +16,7 @@ class MacrosPlugin final : public ExtensionSystem::IPlugin
|
||||
public:
|
||||
~MacrosPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
private:
|
||||
class MacrosPluginPrivate *d = nullptr;
|
||||
|
@@ -68,19 +68,14 @@ McuSupportPlugin::~McuSupportPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool McuSupportPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void McuSupportPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
setObjectName("McuSupportPlugin");
|
||||
dd = new McuSupportPluginPrivate;
|
||||
|
||||
dd->m_options.registerQchFiles();
|
||||
dd->m_options.registerExamples();
|
||||
ProjectExplorer::JsonWizardFactory::addWizardPath(":/mcusupport/wizards/");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void McuSupportPlugin::extensionsInitialized()
|
||||
|
@@ -19,7 +19,7 @@ class McuSupportPlugin final : public ExtensionSystem::IPlugin
|
||||
public:
|
||||
~McuSupportPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
void askUserAboutMcuSupportKitsSetup();
|
||||
|
@@ -226,10 +226,9 @@ MercurialPlugin::~MercurialPlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool MercurialPlugin::initialize(const QStringList & /* arguments */, QString * /*errorMessage */)
|
||||
void MercurialPlugin::initialize()
|
||||
{
|
||||
dd = new MercurialPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
void MercurialPlugin::extensionsInitialized()
|
||||
|
@@ -14,7 +14,7 @@ class MercurialPlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~MercurialPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
#ifdef WITH_TESTS
|
||||
|
@@ -69,17 +69,14 @@ MesonProjectPlugin::~MesonProjectPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool MesonProjectPlugin::initialize(const QStringList & /*arguments*/, QString *errorMessage)
|
||||
void MesonProjectPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new MesonProjectPluginPrivate;
|
||||
|
||||
ProjectManager::registerProjectType<MesonProject>(Constants::Project::MIMETYPE);
|
||||
FileIconProvider::registerIconOverlayForFilename(Constants::Icons::MESON, "meson.build");
|
||||
FileIconProvider::registerIconOverlayForFilename(Constants::Icons::MESON, "meson_options.txt");
|
||||
Settings::instance()->readSettings(ICore::settings());
|
||||
return true;
|
||||
}
|
||||
|
||||
} // MesonProjectManager::Internal
|
||||
|
@@ -17,7 +17,7 @@ public:
|
||||
~MesonProjectPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
class MesonProjectPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -58,10 +58,8 @@ ModelEditorPlugin::~ModelEditorPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool ModelEditorPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void ModelEditorPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
d = new ModelEditorPluginPrivate;
|
||||
|
||||
Core::JsExpander::registerGlobalObject<JsExtension>("Modeling");
|
||||
@@ -70,8 +68,6 @@ bool ModelEditorPlugin::initialize(const QStringList &arguments, QString *errorS
|
||||
&d->uiController, &UiController::saveSettings);
|
||||
connect(&d->settingsController, &SettingsController::loadSettings,
|
||||
&d->uiController, &UiController::loadSettings);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void ModelEditorPlugin::extensionsInitialized()
|
||||
|
@@ -19,7 +19,7 @@ public:
|
||||
ModelEditorPlugin();
|
||||
~ModelEditorPlugin();
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
void extensionsInitialized() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
|
||||
|
@@ -1690,11 +1690,9 @@ PerforcePlugin::~PerforcePlugin()
|
||||
dd = nullptr;
|
||||
}
|
||||
|
||||
bool PerforcePlugin::initialize(const QStringList & /* arguments */, QString *errorMessage)
|
||||
void PerforcePlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
dd = new PerforcePluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
#ifdef WITH_TESTS
|
||||
|
@@ -14,7 +14,7 @@ class PerforcePlugin final : public ExtensionSystem::IPlugin
|
||||
|
||||
~PerforcePlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
public:
|
||||
|
@@ -55,13 +55,9 @@ PerfProfilerPlugin::~PerfProfilerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool PerfProfilerPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void PerfProfilerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new PerfProfilerPluginPrivate;
|
||||
return true;
|
||||
}
|
||||
|
||||
PerfSettings *PerfProfilerPlugin::globalSettings()
|
||||
|
@@ -17,7 +17,7 @@ class PerfProfilerPlugin : public ExtensionSystem::IPlugin
|
||||
public:
|
||||
~PerfProfilerPlugin();
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) final;
|
||||
void initialize() final;
|
||||
QVector<QObject *> createTestObjects() const final;
|
||||
|
||||
static PerfSettings *globalSettings();
|
||||
|
@@ -52,16 +52,11 @@ PythonPlugin *PythonPlugin::instance()
|
||||
return m_instance;
|
||||
}
|
||||
|
||||
bool PythonPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void PythonPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new PythonPluginPrivate;
|
||||
|
||||
ProjectManager::registerProjectType<PythonProject>(PythonMimeType);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void PythonPlugin::extensionsInitialized()
|
||||
|
@@ -19,7 +19,7 @@ public:
|
||||
static PythonPlugin *instance();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
class PythonPluginPrivate *d = nullptr;
|
||||
|
@@ -81,11 +81,8 @@ QbsProjectManagerPlugin::~QbsProjectManagerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool QbsProjectManagerPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void QbsProjectManagerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new QbsProjectManagerPluginPrivate;
|
||||
|
||||
const Core::Context projectContext(::QbsProjectManager::Constants::PROJECT_ID);
|
||||
@@ -248,8 +245,6 @@ bool QbsProjectManagerPlugin::initialize(const QStringList &arguments, QString *
|
||||
updateContextActions(ProjectTree::currentNode());
|
||||
updateReparseQbsAction();
|
||||
updateBuildActions();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void QbsProjectManagerPlugin::targetWasAdded(Target *target)
|
||||
|
@@ -29,7 +29,7 @@ public:
|
||||
private:
|
||||
~QbsProjectManagerPlugin() final;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
void targetWasAdded(ProjectExplorer::Target *target);
|
||||
void projectChanged(QbsProject *project);
|
||||
|
@@ -128,10 +128,8 @@ QmakeProjectManagerPlugin::~QmakeProjectManagerPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool QmakeProjectManagerPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void QmakeProjectManagerPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
const Context projectContext(QmakeProjectManager::Constants::QMAKEPROJECT_ID);
|
||||
Context projectTreeContext(ProjectExplorer::Constants::C_PROJECT_TREE);
|
||||
|
||||
@@ -291,8 +289,6 @@ bool QmakeProjectManagerPlugin::initialize(const QStringList &arguments, QString
|
||||
d, &QmakeProjectManagerPluginPrivate::updateBuildFileAction);
|
||||
|
||||
d->updateActions();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
QmakeProjectManagerPluginPrivate::~QmakeProjectManagerPluginPrivate()
|
||||
|
@@ -25,7 +25,7 @@ private slots:
|
||||
#endif
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
|
||||
class QmakeProjectManagerPluginPrivate *d = nullptr;
|
||||
};
|
||||
|
@@ -101,14 +101,9 @@ QmlJSEditorPlugin::~QmlJSEditorPlugin()
|
||||
m_instance = nullptr;
|
||||
}
|
||||
|
||||
bool QmlJSEditorPlugin::initialize(const QStringList &arguments, QString *errorMessage)
|
||||
void QmlJSEditorPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
d = new QmlJSEditorPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
QmlJSEditorPluginPrivate::QmlJSEditorPluginPrivate()
|
||||
|
@@ -27,7 +27,7 @@ public:
|
||||
static QuickToolBar *quickToolBar();
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
ShutdownFlag aboutToShutdown() final;
|
||||
|
||||
|
@@ -48,14 +48,9 @@ QmlJSToolsPlugin::~QmlJSToolsPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool QmlJSToolsPlugin::initialize(const QStringList &arguments, QString *error)
|
||||
void QmlJSToolsPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(error)
|
||||
|
||||
d = new QmlJSToolsPluginPrivate;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
QmlJSToolsPluginPrivate::QmlJSToolsPluginPrivate()
|
||||
|
@@ -17,7 +17,7 @@ public:
|
||||
~QmlJSToolsPlugin() final;
|
||||
|
||||
private:
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) final;
|
||||
void initialize() final;
|
||||
void extensionsInitialized() final;
|
||||
|
||||
class QmlJSToolsPluginPrivate *d = nullptr;
|
||||
|
@@ -198,14 +198,9 @@ QmlPreviewPlugin::~QmlPreviewPlugin()
|
||||
delete d;
|
||||
}
|
||||
|
||||
bool QmlPreviewPlugin::initialize(const QStringList &arguments, QString *errorString)
|
||||
void QmlPreviewPlugin::initialize()
|
||||
{
|
||||
Q_UNUSED(arguments)
|
||||
Q_UNUSED(errorString)
|
||||
|
||||
d = new QmlPreviewPluginPrivate(this);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
ExtensionSystem::IPlugin::ShutdownFlag QmlPreviewPlugin::aboutToShutdown()
|
||||
|
@@ -48,7 +48,7 @@ class QMLPREVIEW_EXPORT QmlPreviewPlugin : public ExtensionSystem::IPlugin
|
||||
public:
|
||||
~QmlPreviewPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorString) override;
|
||||
void initialize() override;
|
||||
ShutdownFlag aboutToShutdown() override;
|
||||
QVector<QObject *> createTestObjects() const override;
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user