Fix wrong unsave state

Document title shows wrong unsave state when open a document with part group existed
master
Jeremy Hu 2020-03-12 23:02:56 +09:30
parent 4eddbaa2b7
commit 9d17f71033
1 changed files with 0 additions and 9 deletions

View File

@ -1105,15 +1105,6 @@ void PartTreeWidget::reloadComponentChildren(const QUuid &componentId)
}
deleteItemChildren(parentItem);
addComponentChildrenToItem(componentId, parentItem);
// Fix the last item show in the wrong place sometimes
int childCount = m_rootItem->childCount();
if (childCount > 0) {
QTreeWidgetItem *lastItem = m_rootItem->child(childCount - 1);
bool isExpanded = lastItem->isExpanded();
lastItem->setExpanded(!isExpanded);
lastItem->setExpanded(isExpanded);
}
}
void PartTreeWidget::removeAllContent()