From 713cdb86a0e0fff17fa425d894e97eafeabac11d Mon Sep 17 00:00:00 2001 From: hjk Date: Fri, 7 Feb 2020 15:48:26 +0100 Subject: [PATCH] Core: Remove QObject parent for IEditorFactory Change-Id: I0b2088c56a86b8c68bbb355d367d062475685063 Reviewed-by: Eike Ziller --- src/plugins/coreplugin/editormanager/ieditorfactory.cpp | 3 +-- src/plugins/coreplugin/editormanager/ieditorfactory.h | 2 +- src/plugins/vcsbase/basevcssubmiteditorfactory.cpp | 4 +--- src/plugins/vcsbase/basevcssubmiteditorfactory.h | 3 +-- 4 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/plugins/coreplugin/editormanager/ieditorfactory.cpp b/src/plugins/coreplugin/editormanager/ieditorfactory.cpp index 82a2ad52273..85cceacc03b 100644 --- a/src/plugins/coreplugin/editormanager/ieditorfactory.cpp +++ b/src/plugins/coreplugin/editormanager/ieditorfactory.cpp @@ -37,8 +37,7 @@ namespace Core { static QList g_editorFactories; static QHash g_userPreferredEditorFactories; -IEditorFactory::IEditorFactory(QObject *parent) - : QObject(parent) +IEditorFactory::IEditorFactory() { g_editorFactories.append(this); } diff --git a/src/plugins/coreplugin/editormanager/ieditorfactory.h b/src/plugins/coreplugin/editormanager/ieditorfactory.h index 20a0baa0e61..01073b4b42d 100644 --- a/src/plugins/coreplugin/editormanager/ieditorfactory.h +++ b/src/plugins/coreplugin/editormanager/ieditorfactory.h @@ -47,7 +47,7 @@ class CORE_EXPORT IEditorFactory : public QObject Q_OBJECT public: - IEditorFactory(QObject *parent = nullptr); + IEditorFactory(); ~IEditorFactory() override; static const EditorFactoryList allEditorFactories(); diff --git a/src/plugins/vcsbase/basevcssubmiteditorfactory.cpp b/src/plugins/vcsbase/basevcssubmiteditorfactory.cpp index be84f19c421..704b43d2f59 100644 --- a/src/plugins/vcsbase/basevcssubmiteditorfactory.cpp +++ b/src/plugins/vcsbase/basevcssubmiteditorfactory.cpp @@ -43,9 +43,7 @@ const char DIFF_SELECTED[] = "Vcs.DiffSelectedFiles"; VcsSubmitEditorFactory::VcsSubmitEditorFactory (const VcsBaseSubmitEditorParameters ¶meters, const EditorCreator &editorCreator, - VcsBasePluginPrivate *plugin, - QObject *parent) - : IEditorFactory(parent) + VcsBasePluginPrivate *plugin) { setId(parameters.id); setDisplayName(QLatin1String(parameters.displayName)); diff --git a/src/plugins/vcsbase/basevcssubmiteditorfactory.h b/src/plugins/vcsbase/basevcssubmiteditorfactory.h index 15386b915a9..133d9fd0ff5 100644 --- a/src/plugins/vcsbase/basevcssubmiteditorfactory.h +++ b/src/plugins/vcsbase/basevcssubmiteditorfactory.h @@ -49,8 +49,7 @@ public: VcsSubmitEditorFactory(const VcsBaseSubmitEditorParameters ¶meters, const EditorCreator &editorCreator, - VcsBasePluginPrivate *plugin, - QObject *parent = nullptr); + VcsBasePluginPrivate *plugin); private: QAction *m_submitAction = nullptr;