mailr10921 - /branches/bieri_gui/gui_bieri/relax_gui.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by michael . bieri on February 25, 2010 - 05:28:
Author: michaelbieri
Date: Thu Feb 25 05:28:45 2010
New Revision: 10921

URL: http://svn.gna.org/viewcvs/relax?rev=10921&view=rev
Log:
A global pdb file can be loaded through the menu Molecule>Load PDB File.

Modified:
    branches/bieri_gui/gui_bieri/relax_gui.py

Modified: branches/bieri_gui/gui_bieri/relax_gui.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/relax_gui.py?rev=10921&r1=10920&r2=10921&view=diff
==============================================================================
--- branches/bieri_gui/gui_bieri/relax_gui.py (original)
+++ branches/bieri_gui/gui_bieri/relax_gui.py Thu Feb 25 05:28:45 2010
@@ -304,7 +304,7 @@
         menubar.Append(menu, "&Molecule")
 
         # The 'Molecule' menu actions.
-        #self.Bind(wx.EVT_MENU, self.structure_pdb,  id=10)
+        self.Bind(wx.EVT_MENU, self.structure_pdb,  id=10)
         self.Bind(wx.EVT_MENU, self.import_seq,     id=11)
 
         # The 'Settings' menu entries.
@@ -459,7 +459,6 @@
 
 
     def import_seq(self, event): # open load sequence panel
-        global sequencefile  #load global variable
         temp = load_sequence(self)
         if not temp == None:
             sequencefile = str(temp) #set sequence file
@@ -728,6 +727,29 @@
         state.save_state(self.save_file, verbosity=0, force=True)
 
 
+    def structure_pdb(self, event): # open load sequence panel
+        temp = load_sequence(self)
+        if not temp == None:
+            structure_file_pdb = str(temp) #set sequence file
+
+            # Add file to NOE tabs.
+            
self.analysis_frames[self.hardcoded_index_noe_1].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_noe_2].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_noe_3].field_structure.SetValue(structure_file_pdb)
+            
+            # Add file to R1 tabs.
+            
self.analysis_frames[self.hardcoded_index_r1_1].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_r1_2].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_r1_3].field_structure.SetValue(structure_file_pdb)
+
+            # Add file to R2 tabs.
+            
self.analysis_frames[self.hardcoded_index_r2_1].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_r2_2].field_structure.SetValue(structure_file_pdb)
+            
self.analysis_frames[self.hardcoded_index_r2_3].field_structure.SetValue(structure_file_pdb)
+
+        event.Skip()
+
+
     def sync_ds(self, upload=False):
         """Synchronise the GUI and the relax data store, both ways.
 




Related Messages


Powered by MHonArc, Updated Thu Feb 25 05:40:02 2010