diff --git a/io_mesh_pdb/__init__.py b/io_mesh_pdb/__init__.py index 3a479dbd1e4504b799a4eb03eaec0726b54cc232..883e998900c1e1df94449ed898a255ca7960e9ef 100644 --- a/io_mesh_pdb/__init__.py +++ b/io_mesh_pdb/__init__.py @@ -75,6 +75,11 @@ class CLASS_atom_pdb_panel(Panel): def draw(self, context): layout = self.layout + + # This is for the case that a blend file is loaded. + if len(context.scene.atom_pdb) == 0: + bpy.context.scene.atom_pdb.add() + scn = context.scene.atom_pdb[0] row = layout.row() diff --git a/io_mesh_pdb/export_pdb.py b/io_mesh_pdb/export_pdb.py index e470036109c89d26d7f86d62dc6d327069ba20dd..ea4a761e584a8980914dd50940bc3d02d2d99d54 100644 --- a/io_mesh_pdb/export_pdb.py +++ b/io_mesh_pdb/export_pdb.py @@ -25,7 +25,7 @@ # # Start of project : 2011-08-31 by Clemens Barth # First publication in Blender : 2011-11-11 -# Last modified : 2012-03-23 +# Last modified : 2012-04-18 # # Acknowledgements: Thanks to ideasman, meta_androcto, truman, kilon, # dairin0d, PKHG, Valter, etc diff --git a/io_mesh_pdb/import_pdb.py b/io_mesh_pdb/import_pdb.py index b4f52af50fc0a2f19554c097e5b5610bcf971dce..e9decb0c1472847eae956026bd459ed5e26bc452 100644 --- a/io_mesh_pdb/import_pdb.py +++ b/io_mesh_pdb/import_pdb.py @@ -25,7 +25,7 @@ # # Start of project : 2011-08-31 by Clemens Barth # First publication in Blender : 2011-11-11 -# Last modified : 2012-03-23 +# Last modified : 2012-04-18 # # Acknowledgements: Thanks to ideasman, meta_androcto, truman, kilon, # dairin0d, PKHG, Valter, etc