Refactor and rename QIconProvider -> IconProvider (#5893)

* Refactor and rename QIconProvider -> IconProvider
* Generate icons on demand as unique_ptrs
This commit is contained in:
Gaute Lindkvist
2020-05-09 11:25:11 +02:00
committed by GitHub
parent b84e868564
commit 2e79cf614f
42 changed files with 383 additions and 379 deletions

View File

@@ -356,7 +356,8 @@ QVariant caf::PdmUiTreeSelectionQModel::data(const QModelIndex &index, int role
}
else if (role == Qt::DecorationRole)
{
return optionItemInfo->icon();
auto icon = optionItemInfo->icon();
return icon ? *icon : QIcon();
}
else if (role == Qt::CheckStateRole && !optionItemInfo->isHeading())
{