diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/command.py | 4 | ||||
| -rw-r--r-- | src/core.py | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/src/command.py b/src/command.py index 74ca821..18f7408 100644 --- a/src/command.py +++ b/src/command.py @@ -64,7 +64,9 @@ class Command(QtCore.QObject): ) if not projPath.endswith('.avp'): projPath += '.avp' - self.core.openProject(self, projPath) + success = self.core.openProject(self, projPath) + if not success: + quit(1) self.core.selectedComponents = list( reversed(self.core.selectedComponents)) self.core.componentListChanged() diff --git a/src/core.py b/src/core.py index b371d64..1c29774 100644 --- a/src/core.py +++ b/src/core.py @@ -214,7 +214,8 @@ class Core: self.clearPreset(i) if hasattr(loader, 'updateComponentTitle'): loader.updateComponentTitle(i, modified) - + self.openingProject = False + return True except Exception: errcode = 1 data = sys.exc_info() @@ -234,7 +235,8 @@ class Core: showCancel=False, icon='Warning', detail=msg) - self.openingProject = False + self.openingProject = False + return False def parseAvFile(self, filepath): ''' |
