diff options
Diffstat (limited to 'src/plugins/debugger/debuggerengine.cpp')
-rw-r--r-- | src/plugins/debugger/debuggerengine.cpp | 48 |
1 files changed, 15 insertions, 33 deletions
diff --git a/src/plugins/debugger/debuggerengine.cpp b/src/plugins/debugger/debuggerengine.cpp index 34df0d02a8..33b3c52197 100644 --- a/src/plugins/debugger/debuggerengine.cpp +++ b/src/plugins/debugger/debuggerengine.cpp @@ -47,7 +47,6 @@ #include "stackhandler.h" #include "threadshandler.h" #include "watchhandler.h" -#include "qtmessageloghandler.h" #include <coreplugin/icore.h> #include <coreplugin/idocument.h> @@ -65,6 +64,8 @@ #include <utils/qtcassert.h> #include <utils/fileinprojectfinder.h> +#include <qmljs/consolemanagerinterface.h> + #include <QDebug> #include <QTimer> #include <QFile> @@ -296,7 +297,6 @@ public: StackHandler m_stackHandler; ThreadsHandler m_threadsHandler; WatchHandler m_watchHandler; - QtMessageLogHandler m_qtMessageHandler; QFutureInterface<void> m_progress; DisassemblerAgent m_disassemblerAgent; @@ -427,11 +427,6 @@ WatchHandler *DebuggerEngine::watchHandler() const : &d->m_watchHandler; } -QtMessageLogHandler *DebuggerEngine::qtMessageLogHandler() const -{ - return &d->m_qtMessageHandler; -} - SourceFilesHandler *DebuggerEngine::sourceFilesHandler() const { return d->m_masterEngine @@ -509,14 +504,6 @@ QAbstractItemModel *DebuggerEngine::sourceFilesModel() const return model; } -QAbstractItemModel *DebuggerEngine::qtMessageLogModel() const -{ - QAbstractItemModel *model = qtMessageLogHandler()->model(); - if (model->objectName().isEmpty()) // Make debugging easier. - model->setObjectName(objectName() + QLatin1String("QtMessageLogModel")); - return model; -} - void DebuggerEngine::fetchMemory(MemoryAgent *, QObject *, quint64 addr, quint64 length) { @@ -545,8 +532,9 @@ void DebuggerEngine::showMessage(const QString &msg, int channel, int timeout) c } //if (msg.size() && msg.at(0).isUpper() && msg.at(1).isUpper()) // qDebug() << qPrintable(msg) << "IN STATE" << state(); - if (channel == QtMessageLogOutput) - qtMessageLogHandler()->appendMessage(QtMessageLogHandler::UndefinedType, msg); + QmlJS::ConsoleManagerInterface *consoleManager = QmlJS::ConsoleManagerInterface::instance(); + if (channel == ConsoleOutput && consoleManager) + consoleManager->printToConsolePane(QmlJS::ConsoleItem::UndefinedType, msg); debuggerCore()->showMessage(msg, channel, timeout); if (d->m_runControl) { @@ -1245,10 +1233,6 @@ void DebuggerEngine::setState(DebuggerState state, bool forced) handler->notifyBreakpointReleased(id); } - const bool running = d->m_state == InferiorRunOk; - if (running) - threadsHandler()->notifyRunning(); - showMessage(msg, LogDebug); updateViews(); @@ -1467,6 +1451,10 @@ void DebuggerEngine::requestModuleSymbols(const QString &) { } +void DebuggerEngine::requestModuleSections(const QString &) +{ +} + void DebuggerEngine::reloadRegisters() { } @@ -1598,10 +1586,6 @@ void DebuggerEngine::changeBreakpoint(BreakpointModelId id) QTC_CHECK(false); } -void DebuggerEngine::selectThread(int) -{ -} - void DebuggerEngine::assignValueInDebugger(const WatchData *, const QString &, const QVariant &) { @@ -1667,12 +1651,6 @@ void DebuggerEngine::executeDebuggerCommand(const QString &, DebuggerLanguages) showStatusMessage(tr("This debugger cannot handle user input.")); } -bool DebuggerEngine::evaluateScriptExpression(const QString &) -{ - showStatusMessage(tr("This debugger cannot handle user input.")); - return false; -} - BreakHandler *DebuggerEngine::breakHandler() const { return debuggerCore()->breakHandler(); @@ -1955,8 +1933,12 @@ TaskHub *DebuggerEnginePrivate::taskHub() { if (!m_taskHub) { m_taskHub = ProjectExplorerPlugin::instance()->taskHub(); - m_taskHub->addCategory(Core::Id("Debuginfo"), tr("Debug Information")); - m_taskHub->addCategory(Core::Id("DebuggerTest"), tr("Debugger Test")); + m_taskHub->addCategory(Core::Id(Debugger::Constants::TASK_CATEGORY_DEBUGGER_DEBUGINFO), + tr("Debug Information")); + m_taskHub->addCategory(Core::Id(Debugger::Constants::TASK_CATEGORY_DEBUGGER_TEST), + tr("Debugger Test")); + m_taskHub->addCategory(Core::Id(Debugger::Constants::TASK_CATEGORY_DEBUGGER_RUNTIME), + tr("Debugger Runtime")); } return m_taskHub; } |