From 9e85d6c8941a303edc2b99a076d17f4298cc4978 Mon Sep 17 00:00:00 2001 From: Youness Alaoui Date: Fri, 16 Dec 2016 12:59:37 -0500 Subject: [PATCH] Fix GCodeReader-feature related _readMeshfinished to match changes upstream. The job.getResult() now returns a list of nodes now, so we need to loop over those nodes instead of taking it as a single node value. --- cura/CuraApplication.py | 4 ++-- plugins/3MFReader/ThreeMFReader.py | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index 45221738be..54f4cf3057 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -1056,11 +1056,11 @@ class CuraApplication(QtApplication): job.start() def _readMeshFinished(self, job): - node = job.getResult() + nodes = job.getResult() filename = job.getFileName() self._currently_loading_files.remove(filename) - if node != None: + for node in nodes: node.setSelectable(True) node.setName(os.path.basename(filename)) diff --git a/plugins/3MFReader/ThreeMFReader.py b/plugins/3MFReader/ThreeMFReader.py index ee4e1daab4..e9f0e28511 100644 --- a/plugins/3MFReader/ThreeMFReader.py +++ b/plugins/3MFReader/ThreeMFReader.py @@ -1,7 +1,6 @@ # Copyright (c) 2015 Ultimaker B.V. # Cura is released under the terms of the AGPLv3 or higher. -import math import os.path import zipfile