diff --git a/src/plugins/debugger/qml/qmlcppengine.cpp b/src/plugins/debugger/qml/qmlcppengine.cpp
index 62b7c1f3a055d2b6e9f79021d46e7c27b9b36380..051243153ab6ebdb15ff34edae503acff0f8f44b 100644
--- a/src/plugins/debugger/qml/qmlcppengine.cpp
+++ b/src/plugins/debugger/qml/qmlcppengine.cpp
@@ -120,7 +120,7 @@ QmlCppEngine::QmlCppEngine(const DebuggerStartParameters &sp,
         *errorMessage = tr("The slave debugging engine required for combined QML/C++-Debugging could not be created: %1").arg(*errorMessage);
         return;
     }
-    d->m_activeEngine = d->m_cppEngine;
+    setActiveEngine(d->m_cppEngine);
 }
 
 QmlCppEngine::~QmlCppEngine()
@@ -425,7 +425,7 @@ bool QmlCppEngine::evaluateScriptExpression(const QString &expression)
 void QmlCppEngine::setupEngine()
 {
     EDEBUG("\nMASTER SETUP ENGINE");
-    d->m_activeEngine = d->m_cppEngine;
+    setActiveEngine(d->m_cppEngine);
     d->m_qmlEngine->setupSlaveEngine();
     d->m_cppEngine->setupSlaveEngine();
 
@@ -592,7 +592,7 @@ void QmlCppEngine::slaveEngineStateChanged
                 // track qml engine again
                 setState(InferiorStopRequested);
                 notifyInferiorStopOk();
-                d->m_activeEngine = qmlEngine();
+                setActiveEngine(d->m_qmlEngine);
             }
             break;
         }
@@ -625,7 +625,7 @@ void QmlCppEngine::slaveEngineStateChanged
                     setState(InferiorStopRequested);
                 }
                 // now track cpp engine
-                d->m_activeEngine = cppEngine();
+                setActiveEngine(d->m_cppEngine);
             }
             break;
         }
@@ -637,7 +637,7 @@ void QmlCppEngine::slaveEngineStateChanged
                            || state() == InferiorStopOk, qDebug() << state());
 
                 // Just to make sure, we're shutting down anyway ...
-                d->m_activeEngine = cppEngine();
+                setActiveEngine(d->m_cppEngine);
 
                 if (state() == InferiorStopRequested)
                     setState(InferiorStopOk);
@@ -645,7 +645,7 @@ void QmlCppEngine::slaveEngineStateChanged
             } else {
                 if (d->m_activeEngine != cppEngine()) {
                     showStatusMessage(tr("C++ debugger activated"));
-                    d->m_activeEngine = cppEngine();
+                    setActiveEngine(d->m_cppEngine);
                 }
 
                 QTC_ASSERT(state() == InferiorStopRequested
@@ -737,7 +737,7 @@ void QmlCppEngine::slaveEngineStateChanged
                 EDEBUG("... QML ENGINE STOPPED DURING SHUTDOWN ");
 
                 // Just to make sure, we're shutting down anyway ...
-                d->m_activeEngine = cppEngine();
+                setActiveEngine(d->m_cppEngine);
 
                 if (state() == InferiorStopRequested)
                     notifyInferiorStopOk();
@@ -745,7 +745,7 @@ void QmlCppEngine::slaveEngineStateChanged
             } else {
                 if (d->m_activeEngine != qmlEngine()) {
                     showStatusMessage(tr("QML debugger activated"));
-                    d->m_activeEngine = qmlEngine();
+                    setActiveEngine(d->m_qmlEngine);
                 }
 
                 QTC_ASSERT(state() == InferiorRunOk
@@ -821,6 +821,12 @@ DebuggerEngine *QmlCppEngine::qmlEngine() const
     return d->m_qmlEngine;
 }
 
+void QmlCppEngine::setActiveEngine(DebuggerEngine *engine)
+{
+    d->m_activeEngine = engine;
+    updateViews();
+}
+
 } // namespace Internal
 } // namespace Debugger
 
diff --git a/src/plugins/debugger/qml/qmlcppengine.h b/src/plugins/debugger/qml/qmlcppengine.h
index 7cd2c10be92af99a23f3918abe82071ad18656b7..5966239632801af15e8bed0816800f487a66ad04 100644
--- a/src/plugins/debugger/qml/qmlcppengine.h
+++ b/src/plugins/debugger/qml/qmlcppengine.h
@@ -138,6 +138,7 @@ private:
     void slaveEngineStateChanged(DebuggerEngine *slaveEngine, DebuggerState state);
 
     void readyToExecuteQmlStep();
+    void setActiveEngine(DebuggerEngine *engine);
 
 private:
     QmlCppEnginePrivate *d;