mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-11-02 20:52:20 -07:00
Do not use a lambda but a member function so reloading works properly
Fixes #99
This commit is contained in:
parent
937ba1d317
commit
ef86eb480f
1 changed files with 5 additions and 1 deletions
|
|
@ -330,7 +330,8 @@ class CuraApplication(QtApplication):
|
||||||
file_name = node.getMeshData().getFileName()
|
file_name = node.getMeshData().getFileName()
|
||||||
if file_name:
|
if file_name:
|
||||||
job = ReadMeshJob(file_name)
|
job = ReadMeshJob(file_name)
|
||||||
job.finished.connect(lambda j: node.setMeshData(j.getResult()))
|
job._node = node
|
||||||
|
job.finished.connect(self._reloadMeshFinished)
|
||||||
job.start()
|
job.start()
|
||||||
|
|
||||||
## Get logging data of the backend engine
|
## Get logging data of the backend engine
|
||||||
|
|
@ -538,3 +539,6 @@ class CuraApplication(QtApplication):
|
||||||
|
|
||||||
Preferences.getInstance().setValue("cura/recent_files", pref)
|
Preferences.getInstance().setValue("cura/recent_files", pref)
|
||||||
self.recentFilesChanged.emit()
|
self.recentFilesChanged.emit()
|
||||||
|
|
||||||
|
def _reloadMeshFinished(self, job):
|
||||||
|
job._node.setMeshData(job.getResult())
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue