mailr13657 - /branches/gui_testing/status.py


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

Header


Content

Posted by edward on July 15, 2011 - 18:53:
Author: bugman
Date: Fri Jul 15 18:52:59 2011
New Revision: 13657

URL: http://svn.gna.org/viewcvs/relax?rev=13657&view=rev
Log:
Added a reset() method to the Observer class to remove all callback functions.


Modified:
    branches/gui_testing/status.py

Modified: branches/gui_testing/status.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/gui_testing/status.py?rev=13657&r1=13656&r2=13657&view=diff
==============================================================================
--- branches/gui_testing/status.py (original)
+++ branches/gui_testing/status.py Fri Jul 15 18:52:59 2011
@@ -277,6 +277,13 @@
         self._callback[key] = method
 
 
+    def reset(self):
+        """Reset the object."""
+
+        # Reinitialise the dictionary of callback methods.
+        self._callback = {}
+
+
     def unregister(self, key):
         """Unregister the method corresponding to the key.
 




Related Messages


Powered by MHonArc, Updated Fri Jul 15 19:00:02 2011