Tidy up RDTreeView expansion handling

This commit is contained in:
baldurk
2019-04-05 13:22:33 +01:00
parent 77269327ef
commit 4311b35038
6 changed files with 72 additions and 97 deletions
+2 -4
View File
@@ -1953,10 +1953,8 @@ void ShaderViewer::updateDebugging()
if(m_Trace->hasLocals)
{
const QString stateprefix = lit("!!@");
RDTreeViewExpansionState expansion;
ui->locals->saveExpansionExternal(expansion, stateprefix, 0);
ui->locals->saveExpansion(expansion, 0);
ui->locals->clear();
@@ -2097,7 +2095,7 @@ void ShaderViewer::updateDebugging()
while(fakeroot.childCount() > 0)
ui->locals->addTopLevelItem(fakeroot.takeChild(0));
ui->locals->applyExternalExpansion(expansion, stateprefix, 0);
ui->locals->applyExpansion(expansion, 0);
}
if(ui->registers->topLevelItemCount() == 0)