QmlDesigner: Fix wrong order after dropping a item in the navigator

The component complete command is reparenting a item so it is appended. To
get the right order the ChildrenChangedCommand should be sent after
ComponentCompletedCommand.

Change-Id: Id4c1025fc7b4d7f25a7db7511029013c24441dd3
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
This commit is contained in:
Marco Bubke
2014-05-08 13:47:57 +02:00
parent 3ab900de7a
commit 0f55582835

View File

@@ -177,16 +177,16 @@ void Qt5InformationNodeInstanceServer::collectItemChangesAndSendChangeCommands()
if (!propertyChangedList.isEmpty())
nodeInstanceClient()->valuesChanged(createValuesChangedCommand(propertyChangedList));
if (!m_parentChangedSet.isEmpty()) {
sendChildrenChangedCommand(m_parentChangedSet.toList());
m_parentChangedSet.clear();
}
if (!m_completedComponentList.isEmpty()) {
nodeInstanceClient()->componentCompleted(createComponentCompletedCommand(m_completedComponentList));
m_completedComponentList.clear();
}
if (!m_parentChangedSet.isEmpty()) {
sendChildrenChangedCommand(m_parentChangedSet.toList());
m_parentChangedSet.clear();
}
slowDownRenderTimer();
nodeInstanceClient()->flush();
nodeInstanceClient()->synchronizeWithClientProcess();