From 2c12d713e39ad3327eb31cf322cd0ded43ce7c23 Mon Sep 17 00:00:00 2001 From: Nino van Hooff Date: Fri, 27 Sep 2019 16:50:28 +0200 Subject: [PATCH] Revert "Do not show the "load project or models" dialog when opening a file from a command line argument" This reverts commit abfd7e92, because the desired behavior has still tbd --- cura/CuraApplication.py | 6 +++--- cura/SingleInstance.py | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index b2970aeeaa..2c225f31e8 100755 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -805,7 +805,7 @@ class CuraApplication(QtApplication): def _onPostStart(self): for file_name in self._files_to_open: - self.callLater(self._openFile, file_name, True) + self.callLater(self._openFile, file_name) for file_name in self._open_file_queue: # Open all the files that were queued up while plug-ins were loading. self.callLater(self._openFile, file_name) @@ -1549,8 +1549,8 @@ class CuraApplication(QtApplication): return job._node.setMeshData(mesh_data) - def _openFile(self, filename, skip_project_file_check = False): - self.readLocalFile(QUrl.fromLocalFile(filename), skip_project_file_check) + def _openFile(self, filename): + self.readLocalFile(QUrl.fromLocalFile(filename)) def _addProfileReader(self, profile_reader): # TODO: Add the profile reader to the list of plug-ins that can be used when importing profiles. diff --git a/cura/SingleInstance.py b/cura/SingleInstance.py index e6e48ea1df..cf07b143c6 100644 --- a/cura/SingleInstance.py +++ b/cura/SingleInstance.py @@ -87,9 +87,9 @@ class SingleInstance: if command == "clear-all": self._application.callLater(lambda: self._application.deleteAll()) - # Command: Load a model or project file + # Command: Load a model file elif command == "open": - self._application.callLater(lambda f, skip_check = payload["filePath"]: self._application._openFile(f, skip_check)) + self._application.callLater(lambda f = payload["filePath"]: self._application._openFile(f)) # Command: Activate the window and bring it to the top. elif command == "focus":