Update rdctype::array to have a more stl-like mutable interface

* For the most part the interface is stl-compatible, but we have a few
  little changes of our own for convenience.
* This class is still needed after deleting the C# UI, because we don't
  want to pass C++ stl structs over module boundaries and possibly run
  into hard to diagnose incompatibilities.
This commit is contained in:
baldurk
2017-11-03 16:01:58 +00:00
parent e8dc6471a3
commit 5e59616a8c
81 changed files with 1924 additions and 1369 deletions
+3 -3
View File
@@ -78,7 +78,7 @@ void APIInspector::addCallstack(rdctype::array<rdctype::str> calls)
ui->callstack->setUpdatesEnabled(false);
ui->callstack->clear();
if(calls.count == 1 && calls[0].count == 0)
if(calls.size() == 1 && calls[0].isEmpty())
{
ui->callstack->addItem(tr("Symbols not loaded. Tools -> Resolve Symbols."));
}
@@ -99,7 +99,7 @@ void APIInspector::on_apiEvents_itemSelectionChanged()
APIEvent ev = node->tag().value<APIEvent>();
if(ev.callstack.count > 0)
if(!ev.callstack.isEmpty())
{
m_Ctx.Replay().AsyncInvoke([this, ev](IReplayController *r) {
rdctype::array<rdctype::str> trace = r->GetResolve(ev.callstack);
@@ -126,7 +126,7 @@ void APIInspector::fillAPIView()
const DrawcallDescription *draw = m_Ctx.CurSelectedDrawcall();
if(draw != NULL && draw->events.count > 0)
if(draw != NULL && !draw->events.isEmpty())
{
for(const APIEvent &ev : draw->events)
{