Merge branch '15.06'

* 15.06:
  Add a background to the tool additional controls
  Rescale the current layer number based on the maximum layer
  Add a text field style that can be used for generic text fields
  Implemented feature described by #30
  Handle finished signal for the ReadMeshJob started from command line args
  Updated name in menu for firmware update
  Added exception handling to listen thread join
  Render a transparent ghost of the selection when things are selected.
  Fix for #29
This commit is contained in:
Arjen Hiemstra 2015-06-08 16:41:46 +02:00
commit 8c12426760
8 changed files with 212 additions and 26 deletions

View file

@ -162,6 +162,7 @@ class CuraApplication(QtApplication):
for file in self.getCommandLineOption("file", []):
job = ReadMeshJob(os.path.abspath(file))
job.finished.connect(self._onFileLoaded)
job.start()
self.exec_()
@ -447,3 +448,15 @@ class CuraApplication(QtApplication):
def _onMessageActionTriggered(self, message, action):
if action == "eject":
self.getStorageDevice("LocalFileStorage").ejectRemovableDrive(message._sdcard)
def _onFileLoaded(self, job):
mesh = job.getResult()
if mesh != None:
node = SceneNode()
node.setSelectable(True)
node.setMeshData(mesh)
node.setName(os.path.basename(job.getFileName()))
op = AddSceneNodeOperation(node, self.getController().getScene().getRoot())
op.push()