Mercurial > MadButterfly
diff pyink/FSM_window.py @ 1467:6927debad4ee
Fix issue and a simple testcase for FSM
author | Thinker K.F. Li <thinker@codemud.net> |
---|---|
date | Mon, 18 Apr 2011 11:47:52 +0800 |
parents | 59b90d7fcf57 |
children | c1e70540541c |
line wrap: on
line diff
--- a/pyink/FSM_window.py Mon Apr 18 10:23:00 2011 +0800 +++ b/pyink/FSM_window.py Mon Apr 18 11:47:52 2011 +0800 @@ -66,6 +66,8 @@ super(FSM_window, self).__init__() self._locker = domview_ui + + self._domview = domview_ui self._close_cb = close_cb # callback to close editor window (hide) self._destroy_cb = destroy_cb # callback to destroy editor window @@ -86,6 +88,13 @@ def on_FSM_main_win_delete_event(self, *args): self._destroy_cb() pass + + def on_add_state_toggled(self, *args): + domview = self._domview + domview.add_state('test0') + domview.add_state('test1') + domview.add_transition('test0', 'event1', 'test1') + pass pass if __name__ == '__main__':