diff options
author | rahulp13 | 2020-03-02 16:22:43 +0530 |
---|---|---|
committer | rahulp13 | 2020-03-02 16:22:43 +0530 |
commit | 656357024fc225c79b7273ed05672f2d4d797f73 (patch) | |
tree | 0efe8c9212419cbab37564c2ec39b2c10163ef55 /src | |
parent | 0652aab53f84c5b25d489dd85742130425a1c1c9 (diff) | |
download | eSim-656357024fc225c79b7273ed05672f2d4d797f73.tar.gz eSim-656357024fc225c79b7273ed05672f2d4d797f73.tar.bz2 eSim-656357024fc225c79b7273ed05672f2d4d797f73.zip |
resolve issue with changing dir
Diffstat (limited to 'src')
-rw-r--r-- | src/modelEditor/ModelEditor.py | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/modelEditor/ModelEditor.py b/src/modelEditor/ModelEditor.py index d42e3120..0b6990f3 100644 --- a/src/modelEditor/ModelEditor.py +++ b/src/modelEditor/ModelEditor.py @@ -121,7 +121,7 @@ class ModelEditorclass(QtGui.QWidget): self.modeltable.setHidden(True) except BaseException: pass - os.chdir(self.savepathtest) + # Opens new dialog box text, ok = QtGui.QInputDialog.getText( self, 'New Model', 'Enter Model Name:') @@ -312,7 +312,6 @@ class ModelEditorclass(QtGui.QWidget): `self.createtable(path)` - Handle exception of no file selected ''' - os.chdir(self.savepathtest) self.newflag = 0 self.addbtn.setHidden(True) self.types.setHidden(True) @@ -600,6 +599,12 @@ class ModelEditorclass(QtGui.QWidget): ' library created at ' + os.getcwd()) txtfile.close() + + msg = "Model saved successfully!" + QtGui.QMessageBox.information( + self, "Information", msg, QtGui.QMessageBox.Ok + ) + os.chdir(defaultcwd) def validation(self, text): @@ -654,6 +659,11 @@ class ModelEditorclass(QtGui.QWidget): self.obj_appconfig.print_info('Updated library ' + libpath) + msg = "Model saved successfully!" + QtGui.QMessageBox.information( + self, "Information", msg, QtGui.QMessageBox.Ok + ) + def removeparameter(self): ''' - Get the index of the current selected item @@ -676,7 +686,6 @@ class ModelEditorclass(QtGui.QWidget): - Save it in `User Libraries` with the given name, and input from uploaded file ''' - os.chdir(self.savepathtest) self.addbtn.setHidden(True) self.removebtn.setHidden(True) self.modeltable.setHidden(True) |