Commit 19c561c5 authored by Marco Bubke's avatar Marco Bubke
Browse files

QmlDesigner.NodeInstances: Don't send empty image for preview



Change-Id: I0bb327edd702d395023f433e5225a85ecec02d4a
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
parent dffb1cde
...@@ -75,7 +75,9 @@ void Qt5PreviewNodeInstanceServer::collectItemChangesAndSendChangeCommands() ...@@ -75,7 +75,9 @@ void Qt5PreviewNodeInstanceServer::collectItemChangesAndSendChangeCommands()
foreach (ServerNodeInstance instance, rootNodeInstance().stateInstances()) { foreach (ServerNodeInstance instance, rootNodeInstance().stateInstances()) {
instance.activateState(); instance.activateState();
imageContainerVector.append(ImageContainer(instance.instanceId(), renderPreviewImage(), instance.instanceId())); QImage previewImage = renderPreviewImage();
if (!previewImage.isNull())
imageContainerVector.append(ImageContainer(instance.instanceId(), renderPreviewImage(), instance.instanceId()));
instance.deactivateState(); instance.deactivateState();
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment