Author: bugman Date: Thu Jun 23 21:19:52 2011 New Revision: 13206 URL: http://svn.gna.org/viewcvs/relax?rev=13206&view=rev Log: The wizard's run() method now returns a status value. Modified: branches/gui_testing/gui/wizard.py Modified: branches/gui_testing/gui/wizard.py URL: http://svn.gna.org/viewcvs/relax/branches/gui_testing/gui/wizard.py?rev=13206&r1=13205&r2=13206&view=diff ============================================================================== --- branches/gui_testing/gui/wizard.py (original) +++ branches/gui_testing/gui/wizard.py Thu Jun 23 21:19:52 2011 @@ -718,6 +718,9 @@ # Centre the dialog. self.Centre() + # Initialise the wizard status. + self._status = True + # Initialise the page storage. self._current_page = 0 self._num_pages = 0 @@ -834,6 +837,9 @@ @type event: wx event """ + # Change the status. + self._status = False + # Destroy the window. self.Destroy() @@ -968,7 +974,11 @@ def run(self): - """Execute the wizard.""" + """Execute the wizard. + + @return: The status, i.e. True if the wizard is run, False if cancelled or other error occur. + @rtype: bool + """ # Build the buttons for the entire wizard. self._build_buttons() @@ -981,3 +991,6 @@ # Destroy the wizard. self.Destroy() + + # Return the status. + return self._status