forked from qt-creator/qt-creator
debugger: fix disabling of breakpoints using the context menu
Reviewed-by: Robert Loehning Task-number: QTCREATORBUG-2543, QTCREATORBUG-2544
This commit is contained in:
@@ -326,7 +326,7 @@ void DebuggerEnginePrivate::breakpointSetRemoveMarginActionTriggered()
|
||||
QAction *act = qobject_cast<QAction *>(sender());
|
||||
QTC_ASSERT(act, return);
|
||||
QList<QVariant> list = act->data().toList();
|
||||
QTC_ASSERT(list.size() >= 3, return);
|
||||
QTC_ASSERT(list.size() >= 3, qDebug() << list; return);
|
||||
const QString fileName = list.at(0).toString();
|
||||
const int lineNumber = list.at(1).toInt();
|
||||
const quint64 address = list.at(2).toULongLong();
|
||||
@@ -338,7 +338,7 @@ void DebuggerEnginePrivate::breakpointEnableDisableMarginActionTriggered()
|
||||
QAction *act = qobject_cast<QAction *>(sender());
|
||||
QTC_ASSERT(act, return);
|
||||
QList<QVariant> list = act->data().toList();
|
||||
QTC_ASSERT(list.size() == 2, return);
|
||||
QTC_ASSERT(list.size() == 3, qDebug() << list; return);
|
||||
const QString fileName = list.at(0).toString();
|
||||
const int lineNumber = list.at(1).toInt();
|
||||
m_breakHandler.toggleBreakpointEnabled(fileName, lineNumber);
|
||||
@@ -347,7 +347,7 @@ void DebuggerEnginePrivate::breakpointEnableDisableMarginActionTriggered()
|
||||
void DebuggerEnginePrivate::handleContextMenuRequest(const QVariant ¶meters)
|
||||
{
|
||||
const QList<QVariant> list = parameters.toList();
|
||||
QTC_ASSERT(list.size() == 3, return);
|
||||
QTC_ASSERT(list.size() == 3, qDebug() << list; return);
|
||||
TextEditor::ITextEditor *editor =
|
||||
(TextEditor::ITextEditor *)(list.at(0).value<quint64>());
|
||||
int lineNumber = list.at(1).toInt();
|
||||
|
||||
Reference in New Issue
Block a user