diff --git a/src/plugins/coreplugin/progressmanager/progressmanager.cpp b/src/plugins/coreplugin/progressmanager/progressmanager.cpp index c274cdc18f51f8bbb59306f832852b7ddf626907..f45845cd1436b5d461980f150f2c669238e83b4f 100644 --- a/src/plugins/coreplugin/progressmanager/progressmanager.cpp +++ b/src/plugins/coreplugin/progressmanager/progressmanager.cpp @@ -264,6 +264,8 @@ using namespace Core::Internal; Sent when all tasks of a \a type have finished. */ +static ProgressManagerPrivate *m_instance = 0; + ProgressManagerPrivate::ProgressManagerPrivate() : m_applicationTask(0), m_currentStatusDetailsWidget(0), @@ -271,6 +273,7 @@ ProgressManagerPrivate::ProgressManagerPrivate() m_progressViewPinned(false), m_hovered(false) { + m_instance = this; m_progressView = new ProgressView; // withDelay, so the statusBarWidget has the chance to get the enter event connect(m_progressView, SIGNAL(hoveredChanged(bool)), this, SLOT(updateVisibilityWithDelay())); @@ -284,6 +287,7 @@ ProgressManagerPrivate::~ProgressManagerPrivate() ExtensionSystem::PluginManager::removeObject(m_statusBarWidgetContainer); delete m_statusBarWidgetContainer; cleanup(); + m_instance = 0; } void ProgressManagerPrivate::readSettings() @@ -717,16 +721,12 @@ void ToggleButton::paintEvent(QPaintEvent *event) } -static ProgressManager *m_instance = 0; - ProgressManager::ProgressManager() { - m_instance = this; } ProgressManager::~ProgressManager() { - m_instance = 0; } QObject *ProgressManager::instance() diff --git a/src/plugins/coreplugin/progressmanager/progressmanager.h b/src/plugins/coreplugin/progressmanager/progressmanager.h index 32031f71a4e2a565214a32478950e99bbb62238b..392d710762c50fa5e09546eef255d172ccc9bb31 100644 --- a/src/plugins/coreplugin/progressmanager/progressmanager.h +++ b/src/plugins/coreplugin/progressmanager/progressmanager.h @@ -66,12 +66,6 @@ signals: void taskStarted(Core::Id type); void allTasksFinished(Core::Id type); -protected: - virtual void doCancelTasks(Core::Id type) = 0; - virtual FutureProgress *doAddTask(const QFuture<void> &future, const QString &title, - Core::Id type, ProgressFlags flags = 0) = 0; - virtual void doSetApplicationLabel(const QString &text) = 0; - private: ProgressManager(); ~ProgressManager();