#4599 AppFwk : Do not scroll to item when item is collapsed

This commit is contained in:
Magne Sjaastad 2019-08-20 10:35:30 +02:00
parent 97c795cda4
commit d065014571

View File

@ -332,7 +332,11 @@ void PdmUiTreeViewEditor::setExpanded(const PdmUiItem* uiItem, bool doExpand) co
{
QModelIndex index = m_treeViewModel->findModelIndex(uiItem);
m_treeView->setExpanded(index, doExpand);
m_treeView->scrollTo(index);
if (doExpand)
{
m_treeView->scrollTo(index);
}
}
//--------------------------------------------------------------------------------------------------