mail[Wesnoth-commits] r43712 - /trunk/src/whiteboard/side_actions.cpp


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

Header


Content

Posted by gabrielmorin on June 25, 2010 - 02:11:
Author: gabba
Date: Fri Jun 25 02:11:47 2010
New Revision: 43712

URL: http://svn.gna.org/viewcvs/wesnoth?rev=43712&view=rev
Log:
Whiteboard: verify move has been completed before erasing.

Modified:
    trunk/src/whiteboard/side_actions.cpp

Modified: trunk/src/whiteboard/side_actions.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/whiteboard/side_actions.cpp?rev=43712&r1=43711&r2=43712&view=diff
==============================================================================
--- trunk/src/whiteboard/side_actions.cpp (original)
+++ trunk/src/whiteboard/side_actions.cpp Fri Jun 25 02:11:47 2010
@@ -55,9 +55,11 @@
 void side_actions::execute(action_ptr action)
 {
        assert(!actions_.empty());
-       action->execute();
-       remove_action(action);
-       // check if finish ?
+       bool finished = action->execute();
+       if (finished)
+       {
+               remove_action(action);
+       }
        //TODO: Validate remaining actions here
 }
 




Related Messages


Powered by MHonArc, Updated Fri Jun 25 09:40:25 2010