summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorhjk <qtc-committer@nokia.com>2010-06-22 12:02:24 +0200
committerhjk <qtc-committer@nokia.com>2010-06-22 12:04:56 +0200
commitf1cd284a332a9ba9184362d010a4fd10b00f1776 (patch)
treeb7ac326ee4d24e6c74daa691d1b00e6d06d0ec6d /src/plugins
parent0f1290b0c0fb8a9756d0054c3854f174fbccac87 (diff)
downloadqt-creator-f1cd284a332a9ba9184362d010a4fd10b00f1776.tar.gz
debugger: connect some loose ends
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/debugger/debuggerconstants.h1
-rw-r--r--src/plugins/debugger/debuggerengine.cpp11
-rw-r--r--src/plugins/debugger/debuggerengine.h1
-rw-r--r--src/plugins/debugger/debuggerplugin.cpp30
4 files changed, 20 insertions, 23 deletions
diff --git a/src/plugins/debugger/debuggerconstants.h b/src/plugins/debugger/debuggerconstants.h
index ca15e37150..e17cfa7733 100644
--- a/src/plugins/debugger/debuggerconstants.h
+++ b/src/plugins/debugger/debuggerconstants.h
@@ -180,6 +180,7 @@ enum ModelRoles
RequestExecExitRole,
RequestLoadSessionDataRole,
RequestSaveSessionDataRole,
+ RequestOperatedByInstructionTriggeredRole,
// Breakpoints
BreakpointEnabledRole,
diff --git a/src/plugins/debugger/debuggerengine.cpp b/src/plugins/debugger/debuggerengine.cpp
index 5c994407d3..16226caf5f 100644
--- a/src/plugins/debugger/debuggerengine.cpp
+++ b/src/plugins/debugger/debuggerengine.cpp
@@ -260,6 +260,11 @@ bool CommandHandler::setData
case RequestExecFrameUpRole:
m_engine->frameUp();
return true;
+
+ case RequestOperatedByInstructionTriggeredRole:
+ m_engine->gotoLocation(m_engine->stackHandler()->currentFrame(), true);
+ return true;
+
}
return false;
@@ -673,12 +678,6 @@ void DebuggerManager::executeJumpToLine()
}
*/
-void DebuggerEngine::operateByInstructionTriggered()
-{
- StackFrame frame = d->m_stackHandler.currentFrame();
- gotoLocation(frame, true);
-}
-
void DebuggerEngine::cleanup()
{
/*
diff --git a/src/plugins/debugger/debuggerengine.h b/src/plugins/debugger/debuggerengine.h
index b6725632c3..06671e27d8 100644
--- a/src/plugins/debugger/debuggerengine.h
+++ b/src/plugins/debugger/debuggerengine.h
@@ -236,7 +236,6 @@ public:
void executeReturnX();
void executeWatchPointX();
- void operateByInstructionTriggered();
DebuggerState state() const;
// Dumper stuff (common to cdb and gdb).
diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp
index 6ed413fc7d..185192fbf1 100644
--- a/src/plugins/debugger/debuggerplugin.cpp
+++ b/src/plugins/debugger/debuggerplugin.cpp
@@ -772,17 +772,12 @@ public slots:
void updateWatchersHeader(int section, int, int newSize)
{ m_watchersWindow->header()->resizeSection(section, newSize); }
- void reloadSourceFiles()
- { notifyCurrentEngine(RequestReloadSourceFilesRole); }
-
void sourceFilesDockToggled(bool on)
- { if (on) reloadSourceFiles(); }
-
- void reloadModules()
- { notifyCurrentEngine(RequestReloadModulesRole); }
-
+ { if (on) notifyCurrentEngine(RequestReloadSourceFilesRole); }
void modulesDockToggled(bool on)
- { if (on) reloadModules(); }
+ { if (on) notifyCurrentEngine(RequestReloadModulesRole); }
+ void registerDockToggled(bool on)
+ { if (on) notifyCurrentEngine(RequestReloadRegistersRole); }
void onAction();
void setSimpleDockWidgetArrangement(const QString &activeLanguage);
@@ -851,9 +846,7 @@ public slots:
void resetLocation();
void gotoLocation(const QString &file, int line, bool setMarker);
- void registerDockToggled(bool on) {} // FIXME
void clearStatusMessage();
- void operateByInstructionTriggered() {} // FIXME
void sessionLoaded();
void aboutToUnloadSession();
@@ -1122,6 +1115,9 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments, QString *er
m_actions.frameUpAction->setData(RequestExecFrameUpRole);
m_actions.reverseDirectionAction->setCheckable(false);
+ theDebuggerAction(OperateByInstruction)->
+ setData(RequestOperatedByInstructionTriggeredRole);
+
connect(m_actions.continueAction, SIGNAL(triggered()), SLOT(onAction()));
connect(m_actions.nextAction, SIGNAL(triggered()), SLOT(onAction()));
connect(m_actions.stepAction, SIGNAL(triggered()), SLOT(onAction()));
@@ -1146,7 +1142,7 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments, QString *er
SLOT(executeDebuggerCommand()));
connect(theDebuggerAction(OperateByInstruction), SIGNAL(triggered()),
- SLOT(operateByInstructionTriggered()));
+ SLOT(onAction()));
m_plugin->readSettings();
@@ -1160,26 +1156,28 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments, QString *er
// Dock widgets
m_breakDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_breakWindow);
+
m_modulesDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_modulesWindow,
Qt::TopDockWidgetArea, false);
-
connect(m_modulesDock->toggleViewAction(), SIGNAL(toggled(bool)),
- this, SLOT(reloadModules()), Qt::QueuedConnection);
+ SLOT(modulesDockToggled(bool)), Qt::QueuedConnection);
m_registerDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_registerWindow,
Qt::TopDockWidgetArea, false);
connect(m_registerDock->toggleViewAction(), SIGNAL(toggled(bool)),
- m_registerWindow, SLOT(reloadRegisters()), Qt::QueuedConnection);
+ SLOT(registerDockToggled(bool)), Qt::QueuedConnection);
m_outputDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_outputWindow,
Qt::TopDockWidgetArea, false);
m_snapshotDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_snapshotWindow);
+
m_stackDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_stackWindow);
+
m_sourceFilesDock = m_uiSwitcher->createDockWidget(LANG_CPP,
m_sourceFilesWindow, Qt::TopDockWidgetArea, false);
connect(m_sourceFilesDock->toggleViewAction(), SIGNAL(toggled(bool)),
- this, SLOT(reloadSourceFiles()), Qt::QueuedConnection);
+ SLOT(sourceFilesDockToggled(bool)), Qt::QueuedConnection);
m_threadsDock = m_uiSwitcher->createDockWidget(LANG_CPP, m_threadsWindow);