Commit 7f6dbbb3 authored by hjk's avatar hjk
Browse files

Debugger: Use direct access to WatchItems in PDB engine



Change-Id: I4229cab0304160f1b47ee17f25fa7d30414bbe85
Reviewed-by: default avatarhjk <hjk@theqtcompany.com>
parent 39ab4b37
......@@ -800,16 +800,20 @@ void PdbEngine::handleListLocals(const PdbResponse &response)
//qDebug() << "ALL: " << all.toString();
//GdbMi data = all.findChild("data");
QList<WatchData> list;
WatchHandler *handler = watchHandler();
QSet<QByteArray> toDelete;
foreach (WatchItem *item, handler->model()->treeLevelItems<WatchItem *>(2))
toDelete.insert(item->d.iname);
foreach (const GdbMi &child, all.children()) {
WatchData dummy;
dummy.iname = child["iname"].data();
dummy.name = _(child["name"].data());
//qDebug() << "CHILD: " << child.toString();
parseWatchData(handler->expandedINames(), dummy, child, &list);
WatchItem *item = new WatchItem(child["iname"].data(), _(child["name"].data()));
item->parseWatchData(handler->expandedINames(), child);
handler->insertItem(item);
toDelete.remove(item->d.iname);
}
handler->insertData(list);
handler->purgeOutdatedItems(toDelete);
}
bool PdbEngine::hasCapability(unsigned cap) const
......@@ -822,6 +826,5 @@ DebuggerEngine *createPdbEngine(const DebuggerStartParameters &startParameters)
return new PdbEngine(startParameters);
}
} // namespace Internal
} // namespace Debugger
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment