Commit 78b2f257 authored by hjk's avatar hjk
Browse files

x

parent a3b24d23
......@@ -1489,7 +1489,8 @@ void DebuggerEngine::updateViews()
// The slave engines are not entitled to change the view. Their wishes
// should be coordinated by their master engine.
if (isSlaveEngine())
plugin()->updateState(this);
return;
plugin()->updateState(this);
}
bool DebuggerEngine::isSlaveEngine() const
......
......@@ -287,6 +287,7 @@ public:
virtual void quitDebugger(); // called by DebuggerRunControl
virtual void updateViews();
bool isSlaveEngine() const;
signals:
void stateChanged(const DebuggerState &state);
......@@ -337,7 +338,6 @@ protected:
void setState(DebuggerState state, bool forced = false);
void setSlaveEngine(bool value);
bool isSlaveEngine() const;
protected:
DebuggerRunControl *runControl() const;
......
......@@ -2293,7 +2293,11 @@ void DebuggerPluginPrivate::setInitialState()
void DebuggerPluginPrivate::updateState(DebuggerEngine *engine)
{
QTC_ASSERT(engine != 0 && m_watchersWindow->model() != 0 && m_returnWindow->model() != 0, return);
QTC_ASSERT(engine, return);
QTC_ASSERT(m_watchersWindow->model(), return);
QTC_ASSERT(m_returnWindow->model(), return);
QTC_ASSERT(!engine->isSlaveEngine(), return);
m_threadBox->setCurrentIndex(engine->threadsHandler()->currentThread());
m_watchersWindow->setVisible(
......@@ -2301,14 +2305,16 @@ void DebuggerPluginPrivate::updateState(DebuggerEngine *engine)
m_returnWindow->setVisible(
m_returnWindow->model()->rowCount(QModelIndex()) > 0);
//m_plugin->showMessage(QString("PLUGIN SET STATE: ")
// + DebuggerEngine::stateName(engine->state()), LogStatus);
//qDebug() << "PLUGIN SET STATE: " << engine->state();
if (m_state == engine->state())
return;
m_state = engine->state();
bool actionsEnabled = DebuggerEngine::debuggerActionsEnabled(m_state);
//qDebug() << "PLUGIN SET STATE: " << m_state;
ICore *core = ICore::instance();
ActionManager *am = core->actionManager();
if (m_state == DebuggerNotReady) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment