Do not show the "load project or models" dialog when opening a file from

a command line argument
This commit is contained in:
Nino van Hooff 2019-09-27 16:37:19 +02:00
parent 6b8a195fb4
commit abfd7e9266
2 changed files with 5 additions and 5 deletions

View file

@ -805,7 +805,7 @@ class CuraApplication(QtApplication):
def _onPostStart(self):
for file_name in self._files_to_open:
self.callLater(self._openFile, file_name)
self.callLater(self._openFile, file_name, True)
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):
self.readLocalFile(QUrl.fromLocalFile(filename))
def _openFile(self, filename, skip_project_file_check = False):
self.readLocalFile(QUrl.fromLocalFile(filename), skip_project_file_check)
def _addProfileReader(self, profile_reader):
# TODO: Add the profile reader to the list of plug-ins that can be used when importing profiles.