Debugger: Show confirmed state on breakpoint removal

So far we cheated by pretending removal always succeeds
immediately. Now just draw in grey in the view and remove
fully after the backend confirmed removal.

Change-Id: I0bd607774a3db0fe302b9654798be9dcc50abe8a
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
This commit is contained in:
hjk
2015-02-02 09:29:58 +01:00
parent f99e2570fb
commit 38ec4dd6ae
3 changed files with 30 additions and 4 deletions

View File

@@ -579,6 +579,23 @@ QVariant BreakpointItem::data(int column, int role) const
break;
};
if (role == Qt::ForegroundRole) {
static const QVariant gray(QColor(140, 140, 140));
switch (m_state) {
case BreakpointInsertRequested:
case BreakpointInsertProceeding:
case BreakpointChangeRequested:
case BreakpointChangeProceeding:
case BreakpointRemoveRequested:
case BreakpointRemoveProceeding:
return gray;
case BreakpointInserted:
case BreakpointNew:
case BreakpointDead:
break;
};
}
switch (column) {
case 0:
if (role == Qt::DisplayRole)