From 8a8e5b8cbc29390ca9d0f269c027c8c22aacaf10 Mon Sep 17 00:00:00 2001 From: Francesc M Date: Mon, 2 Mar 2020 22:07:47 +0100 Subject: [PATCH] Fixing cleaning problems --- GitQlientPlugin.cpp | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/GitQlientPlugin.cpp b/GitQlientPlugin.cpp index 486674c..872bf87 100644 --- a/GitQlientPlugin.cpp +++ b/GitQlientPlugin.cpp @@ -32,21 +32,17 @@ GitQlientMode::GitQlientMode() mGitImpl->setObjectName("mainWindow"); } -GitQlientPlugin::GitQlientPlugin() -{ - mGitQlientMode = new GitQlientMode(); -} +GitQlientPlugin::GitQlientPlugin() {} -GitQlientPlugin::~GitQlientPlugin() -{ - delete mGitQlientMode; -} +GitQlientPlugin::~GitQlientPlugin() {} bool GitQlientPlugin::initialize(const QStringList &arguments, QString *errorString) { Q_UNUSED(arguments) Q_UNUSED(errorString) + mGitQlientMode = new GitQlientMode(); + connect(Core::ModeManager::instance(), &Core::ModeManager::currentModeAboutToChange, this, &GitQlientPlugin::aboutToChange);