From 74ce600978984105134e833c2c418f66e8774df7 Mon Sep 17 00:00:00 2001 From: Jack Ha Date: Thu, 16 Feb 2017 15:23:31 +0100 Subject: [PATCH] Comments and removed logs. CURA-3214 --- cura/CuraApplication.py | 1 + plugins/CuraEngineBackend/CuraEngineBackend.py | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index b3fdb4a137..9bb556aeab 100644 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -671,6 +671,7 @@ class CuraApplication(QtApplication): qmlRegisterType(QUrl.fromLocalFile(path), "Cura", 1, 0, type_name) ## Get the backend of the application (the program that does the heavy lifting). + # The backend is also a QObject, which can be used from qml. # \returns Backend \type{Backend} @pyqtSlot(result = "QObject*") def getBackend(self): diff --git a/plugins/CuraEngineBackend/CuraEngineBackend.py b/plugins/CuraEngineBackend/CuraEngineBackend.py index 50ade0b45c..8e832f03f0 100644 --- a/plugins/CuraEngineBackend/CuraEngineBackend.py +++ b/plugins/CuraEngineBackend/CuraEngineBackend.py @@ -36,6 +36,7 @@ class CuraEngineBackend(QObject, Backend): # # This registers all the signal listeners and prepares for communication # with the back-end in general. + # CuraEngineBackend is exposed to qml as well. def __init__(self): super().__init__() # Find out where the engine is located, and how it is called. @@ -190,7 +191,6 @@ class CuraEngineBackend(QObject, Backend): self._stored_optimized_layer_data = [] if self._process is None: - Logger.log("d", "Creating socket and start the engine...") self._createSocket() self.stopSlicing() self._engine_is_fresh = False # Yes we're going to use the engine @@ -203,7 +203,6 @@ class CuraEngineBackend(QObject, Backend): self.slicingStarted.emit() slice_message = self._socket.createMessage("cura.proto.Slice") - Logger.log("d", "Really starting slice job") self._start_slice_job = StartSliceJob.StartSliceJob(slice_message) self._start_slice_job.start() self._start_slice_job.finished.connect(self._onStartSliceCompleted) @@ -569,12 +568,13 @@ class CuraEngineBackend(QObject, Backend): def _onProcessLayersFinished(self, job): self._process_layers_job = None + ## Connect slice function to timer. def enableTimer(self): if not self._use_timer: self._change_timer.timeout.connect(self.slice) self._use_timer = True - ## Disable timer. + ## Disconnect slice function from timer. # This means that slicing will not be triggered automatically def disableTimer(self): if self._use_timer: