mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-05-04 07:04:18 +08:00
parent
1c23549e6d
commit
b55c4d8e46
@ -27,7 +27,7 @@ class ProcessSlicedObjectListJob(Job):
|
||||
|
||||
def run(self):
|
||||
if Application.getInstance().getController().getActiveView().getPluginId() == "LayerView":
|
||||
self._progress = Message(catalog.i18nc("@info:status", "Processing Layers"), 0, False, 0)
|
||||
self._progress = Message(catalog.i18nc("@info:status", "Processing Layers"), 0, False, -1)
|
||||
self._progress.show()
|
||||
|
||||
Application.getInstance().getController().activeViewChanged.connect(self._onActiveViewChanged)
|
||||
@ -52,9 +52,6 @@ class ProcessSlicedObjectListJob(Job):
|
||||
else:
|
||||
center = numpy.array([0.0, 0.0, 0.0])
|
||||
|
||||
if self._progress:
|
||||
self._progress.setProgress(2)
|
||||
|
||||
mesh = MeshData()
|
||||
layer_data = LayerData.LayerData()
|
||||
for object in self._message.objects:
|
||||
@ -80,14 +77,10 @@ class ProcessSlicedObjectListJob(Job):
|
||||
|
||||
layer_data.addPolygon(layer.id, polygon.type, points, polygon.line_width)
|
||||
|
||||
if self._progress:
|
||||
self._progress.setProgress(50)
|
||||
|
||||
# We are done processing all the layers we got from the engine, now create a mesh out of the data
|
||||
layer_data.build()
|
||||
|
||||
if self._progress:
|
||||
self._progress.setProgress(100)
|
||||
|
||||
#Add layerdata decorator to scene node to indicate that the node has layerdata
|
||||
decorator = LayerDataDecorator.LayerDataDecorator()
|
||||
|
Loading…
x
Reference in New Issue
Block a user