Commit 1c7c49e2 authored by hjk's avatar hjk

debugger: reorganize debuggerengine.h

parent 5268b0c8
......@@ -1057,6 +1057,11 @@ bool DebuggerEngine::isSlaveEngine() const
return d->m_masterEngine != 0;
}
DebuggerEngine *DebuggerEngine::masterEngine() const
{
return d->m_masterEngine;
}
bool DebuggerEngine::debuggerActionsEnabled() const
{
return debuggerActionsEnabled(d->m_state);
......
......@@ -133,7 +133,9 @@ public:
DebuggerEngine *parentEngine = 0);
virtual ~DebuggerEngine();
typedef Internal::BreakpointId BreakpointId;
const DebuggerStartParameters &startParameters() const;
DebuggerStartParameters &startParameters();
virtual void setToolTipExpression(const QPoint & mousePos,
TextEditor::ITextEditor *editor, int cursorPos);
......@@ -171,7 +173,7 @@ public:
virtual void createSnapshot();
virtual void updateAll();
typedef Internal::BreakpointId BreakpointId;
virtual bool stateAcceptsBreakpointChanges() const { return true; }
virtual void attemptBreakpointSynchronization();
virtual bool acceptsBreakpoint(BreakpointId id) const = 0;
......@@ -187,33 +189,6 @@ public:
virtual void handleRemoteSetupDone(int gdbServerPort, int qmlPort);
virtual void handleRemoteSetupFailed(const QString &message);
protected:
friend class Internal::DebuggerPluginPrivate;
virtual void detachDebugger();
virtual void exitDebugger();
virtual void executeStep();
virtual void executeStepOut() ;
virtual void executeNext();
virtual void executeStepI();
virtual void executeNextI();
virtual void executeReturn();
virtual void continueInferior();
virtual void interruptInferior();
virtual void requestInterruptInferior();
virtual void executeRunToLine(const QString &fileName, int lineNumber);
virtual void executeRunToFunction(const QString &functionName);
virtual void executeJumpToLine(const QString &fileName, int lineNumber);
virtual void executeDebuggerCommand(const QString &command);
virtual void frameUp();
virtual void frameDown();
public:
const DebuggerStartParameters &startParameters() const;
DebuggerStartParameters &startParameters();
virtual Internal::ModulesHandler *modulesHandler() const;
virtual Internal::RegisterHandler *registerHandler() const;
virtual Internal::StackHandler *stackHandler() const;
......@@ -266,6 +241,7 @@ public:
virtual void updateViews();
bool isSlaveEngine() const;
DebuggerEngine *masterEngine() const;
signals:
void stateChanged(const DebuggerState &state);
......@@ -323,9 +299,29 @@ protected:
virtual void shutdownInferior() = 0;
virtual void shutdownEngine() = 0;
virtual void detachDebugger();
virtual void exitDebugger();
virtual void executeStep();
virtual void executeStepOut() ;
virtual void executeNext();
virtual void executeStepI();
virtual void executeNextI();
virtual void executeReturn();
virtual void continueInferior();
virtual void interruptInferior();
virtual void requestInterruptInferior();
virtual void executeRunToLine(const QString &fileName, int lineNumber);
virtual void executeRunToFunction(const QString &functionName);
virtual void executeJumpToLine(const QString &fileName, int lineNumber);
virtual void executeDebuggerCommand(const QString &command);
virtual void frameUp();
virtual void frameDown();
DebuggerRunControl *runControl() const; // FIXME: Protect.
protected:
static QString msgWatchpointTriggered(BreakpointId id,
int number, quint64 address);
static QString msgWatchpointTriggered(BreakpointId id,
......@@ -345,8 +341,9 @@ protected:
private:
// Wrapper engine needs access to state of its subengines.
friend class Internal::QmlCppEngine;
friend class Internal::DebuggerPluginPrivate;
void setState(DebuggerState state, bool forced = false);
//void setSlaveEngine(bool value);
friend class DebuggerEnginePrivate;
DebuggerEnginePrivate *d;
......
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