diff options
Diffstat (limited to 'io_mesh_atomic/pdb_gui.py')
-rw-r--r-- | io_mesh_atomic/pdb_gui.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/io_mesh_atomic/pdb_gui.py b/io_mesh_atomic/pdb_gui.py index 00a4ca97..f77e2ef4 100644 --- a/io_mesh_atomic/pdb_gui.py +++ b/io_mesh_atomic/pdb_gui.py @@ -203,6 +203,9 @@ class IMPORT_OT_pdb(Operator, ImportHelper): def execute(self, context): + # To be on the safe side, we switch to the 'OBJECT' mode. + bpy.ops.object.mode_set(mode='OBJECT', toggle=False) + # This is in order to solve this strange 'relative path' thing. filepath_pdb = bpy.path.abspath(self.filepath) |