Commit a7eccce7 authored by Friedemann Kleint's avatar Friedemann Kleint

Debugger: Header cleanup

parent f9548e5d
...@@ -35,12 +35,7 @@ ...@@ -35,12 +35,7 @@
#include "breakhandler.h" #include "breakhandler.h"
#include "debuggercore.h" #include "debuggercore.h"
#include <texteditor/basetextmark.h> #include <QtGui/QIcon>
#include <utils/qtcassert.h>
#include <QtCore/QByteArray>
#include <QtCore/QDebug>
////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////
// //
......
...@@ -34,11 +34,8 @@ ...@@ -34,11 +34,8 @@
#ifndef DEBUGGER_BREAKPOINTMARKER_H #ifndef DEBUGGER_BREAKPOINTMARKER_H
#define DEBUGGER_BREAKPOINTMARKER_H #define DEBUGGER_BREAKPOINTMARKER_H
#include <QtCore/QString>
#include <QtGui/QIcon>
#include "breakpoint.h" #include "breakpoint.h"
#include "breakhandler.h"
#include <texteditor/basetextmark.h> #include <texteditor/basetextmark.h>
namespace Debugger { namespace Debugger {
......
...@@ -46,15 +46,9 @@ ...@@ -46,15 +46,9 @@
#include <QtCore/QDebug> #include <QtCore/QDebug>
#include <QtGui/QAction> #include <QtGui/QAction>
#include <QtGui/QHeaderView>
#include <QtGui/QIntValidator> #include <QtGui/QIntValidator>
#include <QtGui/QItemSelectionModel>
#include <QtGui/QKeyEvent> #include <QtGui/QKeyEvent>
#include <QtGui/QMenu> #include <QtGui/QMenu>
#include <QtGui/QResizeEvent>
#include <QtGui/QToolButton>
#include <QtGui/QTreeView>
namespace Debugger { namespace Debugger {
namespace Internal { namespace Internal {
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
#ifndef DEBUGGER_BREAKWINDOW_H #ifndef DEBUGGER_BREAKWINDOW_H
#define DEBUGGER_BREAKWINDOW_H #define DEBUGGER_BREAKWINDOW_H
#include "breakhandler.h" #include "breakpoint.h"
#include <QtGui/QTreeView> #include <QtGui/QTreeView>
......
...@@ -32,6 +32,8 @@ ...@@ -32,6 +32,8 @@
**************************************************************************/ **************************************************************************/
#include "cdbengine2.h" #include "cdbengine2.h"
#include "debuggerstartparameters.h"
#include "disassemblerlines.h"
#include "cdboptions2.h" #include "cdboptions2.h"
#include "cdboptionspage2.h" #include "cdboptionspage2.h"
#include "bytearrayinputstream.h" #include "bytearrayinputstream.h"
...@@ -41,6 +43,7 @@ ...@@ -41,6 +43,7 @@
#include "stackhandler.h" #include "stackhandler.h"
#include "watchhandler.h" #include "watchhandler.h"
#include "threadshandler.h" #include "threadshandler.h"
#include "moduleshandler.h"
#include "debuggeractions.h" #include "debuggeractions.h"
#include "debuggercore.h" #include "debuggercore.h"
#include "registerhandler.h" #include "registerhandler.h"
......
...@@ -36,8 +36,6 @@ ...@@ -36,8 +36,6 @@
#include "registerpostmortemaction.h" #include "registerpostmortemaction.h"
#endif #endif
#include <projectexplorer/toolchain.h>
#include <utils/savedaction.h> #include <utils/savedaction.h>
#include <utils/qtcassert.h> #include <utils/qtcassert.h>
#include <utils/pathchooser.h> #include <utils/pathchooser.h>
...@@ -45,13 +43,6 @@ ...@@ -45,13 +43,6 @@
#include <QtCore/QDebug> #include <QtCore/QDebug>
#include <QtCore/QVariant> #include <QtCore/QVariant>
#include <QtCore/QSettings> #include <QtCore/QSettings>
#include <QtCore/QFileInfo>
#include <QtGui/QAction>
#include <QtGui/QAbstractButton>
#include <QtGui/QRadioButton>
#include <QtGui/QCheckBox>
#include <QtGui/QLineEdit>
using namespace Utils; using namespace Utils;
......
...@@ -35,7 +35,6 @@ ...@@ -35,7 +35,6 @@
#define DEBUGGER_ACTIONS_H #define DEBUGGER_ACTIONS_H
#include <QtCore/QHash> #include <QtCore/QHash>
#include <QtCore/QMap>
QT_BEGIN_NAMESPACE QT_BEGIN_NAMESPACE
class QSettings; class QSettings;
......
...@@ -34,12 +34,9 @@ ...@@ -34,12 +34,9 @@
#ifndef DEBUGGERCORE_H #ifndef DEBUGGERCORE_H
#define DEBUGGERCORE_H #define DEBUGGERCORE_H
#include "debugger_global.h"
#include "debuggerconstants.h" #include "debuggerconstants.h"
#include <QtCore/QObject> #include <QtCore/QObject>
#include <QtCore/QMultiMap>
#include <QtCore/QVector>
QT_BEGIN_NAMESPACE QT_BEGIN_NAMESPACE
class QIcon; class QIcon;
...@@ -58,7 +55,6 @@ class SavedAction; ...@@ -58,7 +55,6 @@ class SavedAction;
namespace Debugger { namespace Debugger {
class DebuggerEngine; class DebuggerEngine;
class DebuggerStartParameters;
namespace Internal { namespace Internal {
......
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#include "debuggerrunner.h" #include "debuggerrunner.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
#include "debuggertooltip.h" #include "debuggertooltip.h"
#include "debuggerstartparameters.h"
#include "memoryagent.h" #include "memoryagent.h"
#include "disassembleragent.h" #include "disassembleragent.h"
...@@ -63,7 +64,6 @@ ...@@ -63,7 +64,6 @@
#include <texteditor/itexteditor.h> #include <texteditor/itexteditor.h>
#include <texteditor/basetextmark.h> #include <texteditor/basetextmark.h>
#include <utils/environment.h>
#include <utils/savedaction.h> #include <utils/savedaction.h>
#include <utils/qtcassert.h> #include <utils/qtcassert.h>
...@@ -95,6 +95,17 @@ using namespace TextEditor; ...@@ -95,6 +95,17 @@ using namespace TextEditor;
namespace Debugger { namespace Debugger {
Internal::Location::Location(const StackFrame &frame, bool marker)
{
init();
m_fileName = frame.file;
m_lineNumber = frame.line;
m_needsMarker = marker;
m_functionName = frame.function;
m_hasDebugInfo = frame.isUsable();
m_address = frame.address;
}
QDebug operator<<(QDebug d, DebuggerState state) QDebug operator<<(QDebug d, DebuggerState state)
{ {
//return d << DebuggerEngine::stateName(state) << '(' << int(state) << ')'; //return d << DebuggerEngine::stateName(state) << '(' << int(state) << ')';
......
...@@ -36,13 +36,7 @@ ...@@ -36,13 +36,7 @@
#include "debugger_global.h" #include "debugger_global.h"
#include "debuggerconstants.h" #include "debuggerconstants.h"
#include "debuggerstartparameters.h"
#include "moduleshandler.h" // For 'Symbols'
#include "breakpoint.h" // For 'BreakpointId' #include "breakpoint.h" // For 'BreakpointId'
#include "stackframe.h"
#include <coreplugin/ssh/sshconnection.h>
#include <utils/environment.h>
#include <QtCore/QObject> #include <QtCore/QObject>
#include <QtCore/QStringList> #include <QtCore/QStringList>
...@@ -51,6 +45,7 @@ QT_BEGIN_NAMESPACE ...@@ -51,6 +45,7 @@ QT_BEGIN_NAMESPACE
class QDebug; class QDebug;
class QPoint; class QPoint;
class QMessageBox; class QMessageBox;
class QAbstractItemModel;
QT_END_NAMESPACE QT_END_NAMESPACE
namespace TextEditor { namespace TextEditor {
...@@ -65,7 +60,7 @@ namespace Debugger { ...@@ -65,7 +60,7 @@ namespace Debugger {
class DebuggerEnginePrivate; class DebuggerEnginePrivate;
class DebuggerRunControl; class DebuggerRunControl;
class DebuggerStartParameters;
DEBUGGER_EXPORT QDebug operator<<(QDebug str, const DebuggerStartParameters &); DEBUGGER_EXPORT QDebug operator<<(QDebug str, const DebuggerStartParameters &);
DEBUGGER_EXPORT QDebug operator<<(QDebug str, DebuggerState state); DEBUGGER_EXPORT QDebug operator<<(QDebug str, DebuggerState state);
...@@ -101,10 +96,7 @@ public: ...@@ -101,10 +96,7 @@ public:
Location(const QString &file) { init(); m_fileName = file; } Location(const QString &file) { init(); m_fileName = file; }
Location(const QString &file, int line, bool marker = true) Location(const QString &file, int line, bool marker = true)
{ init(); m_lineNumber = line; m_fileName = file; m_needsMarker = marker; } { init(); m_lineNumber = line; m_fileName = file; m_needsMarker = marker; }
Location(const StackFrame &frame, bool marker = true) //: m_frame(frame) Location(const StackFrame &frame, bool marker = true);
{ init(); m_fileName = frame.file; m_lineNumber = frame.line;
m_needsMarker = marker; m_functionName = frame.function;
m_hasDebugInfo = frame.isUsable(); m_address = frame.address; }
QString fileName() const { return m_fileName; } QString fileName() const { return m_fileName; }
QString functionName() const { return m_functionName; } QString functionName() const { return m_functionName; }
int lineNumber() const { return m_lineNumber; } int lineNumber() const { return m_lineNumber; }
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "debuggerplugin.h" #include "debuggerplugin.h"
#include "debuggerstartparameters.h"
#include "debuggeractions.h" #include "debuggeractions.h"
#include "debuggerconstants.h" #include "debuggerconstants.h"
#include "debuggercore.h" #include "debuggercore.h"
...@@ -50,6 +51,7 @@ ...@@ -50,6 +51,7 @@
#include "disassembleragent.h" #include "disassembleragent.h"
#include "logwindow.h" #include "logwindow.h"
#include "moduleswindow.h" #include "moduleswindow.h"
#include "moduleshandler.h"
#include "registerwindow.h" #include "registerwindow.h"
#include "snapshotwindow.h" #include "snapshotwindow.h"
#include "stackhandler.h" #include "stackhandler.h"
......
...@@ -38,8 +38,6 @@ ...@@ -38,8 +38,6 @@
#include <extensionsystem/iplugin.h> #include <extensionsystem/iplugin.h>
#include <QtCore/QObject>
namespace ProjectExplorer { namespace ProjectExplorer {
class RunConfiguration; class RunConfiguration;
class RunControl; class RunControl;
......
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#include "debuggermainwindow.h" #include "debuggermainwindow.h"
#include "debuggerplugin.h" #include "debuggerplugin.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
#include "debuggerstartparameters.h"
#include "gdb/gdboptionspage.h" #include "gdb/gdboptionspage.h"
#include "lldb/lldbenginehost.h" #include "lldb/lldbenginehost.h"
......
...@@ -35,7 +35,6 @@ ...@@ -35,7 +35,6 @@
#define DEBUGGERRUNNER_H #define DEBUGGERRUNNER_H
#include "debugger_global.h" #include "debugger_global.h"
#include "debuggerconstants.h"
#include <projectexplorer/runconfiguration.h> #include <projectexplorer/runconfiguration.h>
......
...@@ -35,6 +35,7 @@ ...@@ -35,6 +35,7 @@
#define DEBUGGER_DEBUGGERSTARTPARAMETERS_H #define DEBUGGER_DEBUGGERSTARTPARAMETERS_H
#include "debugger_global.h" #include "debugger_global.h"
#include "debuggerconstants.h"
#include <coreplugin/ssh/sshconnection.h> #include <coreplugin/ssh/sshconnection.h>
#include <utils/environment.h> #include <utils/environment.h>
......
...@@ -33,6 +33,12 @@ ...@@ -33,6 +33,12 @@
#include "debuggerstreamops.h" #include "debuggerstreamops.h"
#include "breakpoint.h"
#include "watchdata.h"
#include "disassemblerlines.h"
#include <QtCore/QDataStream>
namespace Debugger { namespace Debugger {
namespace Internal { namespace Internal {
......
...@@ -34,18 +34,20 @@ ...@@ -34,18 +34,20 @@
#ifndef DEBUGGERPLUGIN_STREAMOPS_H #ifndef DEBUGGERPLUGIN_STREAMOPS_H
#define DEBUGGERPLUGIN_STREAMOPS_H #define DEBUGGERPLUGIN_STREAMOPS_H
#include "breakpoint.h"
#include "stackframe.h"
#include "threaddata.h" #include "threaddata.h"
#include "watchdata.h" #include "stackframe.h"
#include "disassemblerlines.h"
#include <QtCore/QDataStream> QT_FORWARD_DECLARE_CLASS(QDataStream)
#include <QtCore/QVector>
namespace Debugger { namespace Debugger {
namespace Internal { namespace Internal {
class BreakpointParameters;
class BreakpointResponse;
class WatchData;
class DisassemblerLine;
class DisassemblerLines;
QDataStream &operator<<(QDataStream& stream, const ThreadData &thread); QDataStream &operator<<(QDataStream& stream, const ThreadData &thread);
QDataStream &operator>>(QDataStream& stream, ThreadData &threads); QDataStream &operator>>(QDataStream& stream, ThreadData &threads);
QDataStream &operator<<(QDataStream& stream, const Threads &threads); QDataStream &operator<<(QDataStream& stream, const Threads &threads);
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "disassembleragent.h" #include "disassembleragent.h"
#include "disassemblerlines.h"
#include "breakhandler.h" #include "breakhandler.h"
#include "debuggerengine.h" #include "debuggerengine.h"
#include "debuggercore.h" #include "debuggercore.h"
...@@ -54,7 +55,7 @@ ...@@ -54,7 +55,7 @@
#include <QtGui/QTextBlock> #include <QtGui/QTextBlock>
#include <QtGui/QIcon> #include <QtGui/QIcon>
#include <QtCore/QPointer>
using namespace Core; using namespace Core;
......
...@@ -34,21 +34,14 @@ ...@@ -34,21 +34,14 @@
#ifndef DEBUGGER_DISASSEMBLERAGENT_H #ifndef DEBUGGER_DISASSEMBLERAGENT_H
#define DEBUGGER_DISASSEMBLERAGENT_H #define DEBUGGER_DISASSEMBLERAGENT_H
#include "disassemblerlines.h"
#include <QtCore/QObject> #include <QtCore/QObject>
#include <QtCore/QPointer>
namespace Core {
class IEditor;
}
namespace Debugger { namespace Debugger {
class DebuggerEngine; class DebuggerEngine;
namespace Internal { namespace Internal {
class DisassemblerLines;
class Location; class Location;
class DisassemblerAgentPrivate; class DisassemblerAgentPrivate;
...@@ -85,7 +78,6 @@ private: ...@@ -85,7 +78,6 @@ private:
DisassemblerAgentPrivate *d; DisassemblerAgentPrivate *d;
}; };
} // namespace Internal } // namespace Internal
} // namespace Debugger } // namespace Debugger
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "abstractgdbadapter.h" #include "abstractgdbadapter.h"
#include "gdbengine.h" #include "gdbengine.h"
#include "debuggerstartparameters.h"
#include "abstractgdbprocess.h" #include "abstractgdbprocess.h"
#include <utils/qtcassert.h> #include <utils/qtcassert.h>
......
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
#include "abstractplaingdbadapter.h" #include "abstractplaingdbadapter.h"
#include "gdbmi.h" #include "gdbmi.h"
#include "gdbengine.h" #include "gdbengine.h"
#include "debuggerstartparameters.h"
#include "debuggeractions.h" #include "debuggeractions.h"
#include "debuggercore.h" #include "debuggercore.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "attachgdbadapter.h" #include "attachgdbadapter.h"
#include "gdbmi.h" #include "gdbmi.h"
#include "debuggerstartparameters.h"
#include "gdbengine.h" #include "gdbengine.h"
#include "procinterrupt.h" #include "procinterrupt.h"
......
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
#include "gdbengine.h" #include "gdbengine.h"
#include "gdbmi.h" #include "gdbmi.h"
#include "debuggerstartparameters.h"
#include "abstractgdbadapter.h" #include "abstractgdbadapter.h"
#include "debuggeractions.h" #include "debuggeractions.h"
#include "debuggercore.h" #include "debuggercore.h"
...@@ -179,8 +180,7 @@ void GdbEngine::runDebuggingHelperClassic(const WatchData &data0, bool dumpChild ...@@ -179,8 +180,7 @@ void GdbEngine::runDebuggingHelperClassic(const WatchData &data0, bool dumpChild
QByteArray params; QByteArray params;
QList<QByteArray> extraArgs; QList<QByteArray> extraArgs;
const QtDumperHelper::TypeData td = m_dumperHelper.typeData(data0.type); const QtDumperHelper::TypeData td = m_dumperHelper.typeData(data0.type);
m_dumperHelper.evaluationParameters(data, td, QtDumperHelper::GdbDebugger, m_dumperHelper.evaluationParameters(data, td, &params, &extraArgs);
&params, &extraArgs);
//int protocol = (data.iname.startsWith("watch") && data.type == "QImage") ? 3 : 2; //int protocol = (data.iname.startsWith("watch") && data.type == "QImage") ? 3 : 2;
//int protocol = data.iname.startsWith("watch") ? 3 : 2; //int protocol = data.iname.startsWith("watch") ? 3 : 2;
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "coregdbadapter.h" #include "coregdbadapter.h"
#include "debuggerstartparameters.h"
#include "debuggercore.h" #include "debuggercore.h"
#include "debuggeractions.h" #include "debuggeractions.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
......
...@@ -35,6 +35,8 @@ ...@@ -35,6 +35,8 @@
#include "gdbengine.h" #include "gdbengine.h"
#include "debuggerstartparameters.h"
#include "disassemblerlines.h"
#include "attachgdbadapter.h" #include "attachgdbadapter.h"
#include "coregdbadapter.h" #include "coregdbadapter.h"
#include "localplaingdbadapter.h" #include "localplaingdbadapter.h"
......
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
#include "localplaingdbadapter.h" #include "localplaingdbadapter.h"
#include "gdbengine.h" #include "gdbengine.h"
#include "debuggerstartparameters.h"
#include "procinterrupt.h" #include "procinterrupt.h"
#include "debuggercore.h" #include "debuggercore.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "remotegdbserveradapter.h" #include "remotegdbserveradapter.h"
#include "debuggerstartparameters.h"
#include "debuggercore.h" #include "debuggercore.h"
#include "debuggerstringutils.h" #include "debuggerstringutils.h"
#include "gdbengine.h" #include "gdbengine.h"
......
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
#include "remoteplaingdbadapter.h" #include "remoteplaingdbadapter.h"
#include "gdbengine.h" #include "gdbengine.h"
#include "debuggerstartparameters.h"
#include <debugger/debuggeractions.h> #include <debugger/debuggeractions.h>