diff options
author | hjk <[email protected]> | 2016-06-03 12:04:14 +0200 |
---|---|---|
committer | hjk <[email protected]> | 2016-06-07 14:23:14 +0000 |
commit | 36a6585fb5b0d0d37f3d04c5fcaedb1634e37659 (patch) | |
tree | 90161e8aa464d031b058038affc909b677996080 /src/plugins/debugger/breakhandler.cpp | |
parent | b00112290040c22e5adb549af10a6f9bbd464729 (diff) |
Debugger: Introduce enum for columns in breakpoint view
Change-Id: I771c7fceed31739cfe504ba660796d48fb518a5e
Reviewed-by: Christian Stenger <[email protected]>
Diffstat (limited to 'src/plugins/debugger/breakhandler.cpp')
-rw-r--r-- | src/plugins/debugger/breakhandler.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/plugins/debugger/breakhandler.cpp b/src/plugins/debugger/breakhandler.cpp index e2acf17d6c1..57ea837fcc4 100644 --- a/src/plugins/debugger/breakhandler.cpp +++ b/src/plugins/debugger/breakhandler.cpp @@ -602,13 +602,13 @@ QVariant BreakpointItem::data(int column, int role) const } switch (column) { - case 0: + case BreakpointNumberColumn: if (role == Qt::DisplayRole) return m_id.toString(); if (role == Qt::DecorationRole) return icon(); break; - case 1: + case BreakpointFunctionColumn: if (role == Qt::DisplayRole) { if (!m_response.functionName.isEmpty()) return simplifyType(m_response.functionName); @@ -634,7 +634,7 @@ QVariant BreakpointItem::data(int column, int role) const return empty; } break; - case 2: + case BreakpointFileColumn: if (role == Qt::DisplayRole) { QString str; if (!m_response.fileName.isEmpty()) @@ -654,7 +654,7 @@ QVariant BreakpointItem::data(int column, int role) const return empty; } break; - case 3: + case BreakpointLineColumn: if (role == Qt::DisplayRole) { if (m_response.lineNumber > 0) return m_response.lineNumber; @@ -665,7 +665,7 @@ QVariant BreakpointItem::data(int column, int role) const if (role == Qt::UserRole + 1) return m_params.lineNumber; break; - case 4: + case BreakpointAddressColumn: if (role == Qt::DisplayRole) { const quint64 address = orig ? m_params.address : m_response.address; if (address) @@ -673,7 +673,7 @@ QVariant BreakpointItem::data(int column, int role) const return QVariant(); } break; - case 5: + case BreakpointConditionColumn: if (role == Qt::DisplayRole) return orig ? m_params.condition : m_response.condition; if (role == Qt::ToolTipRole) @@ -681,7 +681,7 @@ QVariant BreakpointItem::data(int column, int role) const if (role == Qt::UserRole + 1) return m_params.condition; break; - case 6: + case BreakpointIgnoreColumn: if (role == Qt::DisplayRole) { const int ignoreCount = orig ? m_params.ignoreCount : m_response.ignoreCount; @@ -692,7 +692,7 @@ QVariant BreakpointItem::data(int column, int role) const if (role == Qt::UserRole + 1) return m_params.ignoreCount; break; - case 7: + case BreakpointThreadsColumn: if (role == Qt::DisplayRole) return BreakHandler::displayFromThreadSpec(orig ? m_params.threadSpec : m_response.threadSpec); if (role == Qt::ToolTipRole) |