mailr12906 - /1.3/gui/components/spectrum.py


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

Header


Content

Posted by edward on June 09, 2011 - 10:45:
Author: bugman
Date: Thu Jun  9 10:45:42 2011
New Revision: 12906

URL: http://svn.gna.org/viewcvs/relax?rev=12906&view=rev
Log:
Better behaviour of the deletion of single cells in the Rx peak list grids.

The relaxation time is now cleared, rather than set to 0.0.


Modified:
    1.3/gui/components/spectrum.py

Modified: 1.3/gui/components/spectrum.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/gui/components/spectrum.py?rev=12906&r1=12905&r2=12906&view=diff
==============================================================================
--- 1.3/gui/components/spectrum.py (original)
+++ 1.3/gui/components/spectrum.py Thu Jun  9 10:45:42 2011
@@ -487,6 +487,9 @@
             # Update the grid.
             self.update_grid()
 
+            # Do nothing else.
+            return
+
         # Skip the event to allow for normal operation.
         event.Skip()
 
@@ -778,10 +781,10 @@
         # Loop over the rows.
         for i in range(self.grid.GetNumberRows()):
             # The number of cycles.
-            ncyc = self.grid.GetCellValue(i, 1)
+            ncyc = str(self.grid.GetCellValue(i, 1))
 
             # No time or no cycles, so set the value to nothing.
-            if time == '' or ncyc == '':
+            if time == '' or ncyc in ['', '0']:
                 self.grid.SetCellValue(i, 2, '')
 
             # Update the relaxation time.




Related Messages


Powered by MHonArc, Updated Thu Jun 09 12:00:02 2011