# HG changeset patch # User Thinker K.F. Li # Date 1305043559 -28800 # Node ID fa4d0480d6cba0767408a95ff45d4955461a9e61 # Parent 5d4c7ec05bcd464b4917d4351a8e6cc373d6f54e Switch the component that FSM editor is working on diff -r 5d4c7ec05bcd -r fa4d0480d6cb pyink/comp_dock.py --- a/pyink/comp_dock.py Tue May 10 23:43:12 2011 +0800 +++ b/pyink/comp_dock.py Wed May 11 00:05:59 2011 +0800 @@ -356,19 +356,17 @@ fsm_win.set_svg_view(view_widget) pass - def _show_FSM_editor(self): + def _show_FSM_for_comp(self, comp_name): if not self._fsm_editor_win: self._prepare_FSM_editor() fsm_win = self._fsm_editor_win else: fsm_win = self._fsm_editor_win pass + fsm_win.switch_component(comp_name) fsm_win.show() pass - def _show_FSM_for_comp(self, comp_name): - pass - def on_add_comp_clicked(self, *args): self._add_component() self._drop_undo() @@ -442,7 +440,6 @@ ## \brief User clicks "State Machine" on context menu for a component. # def on_edit_FSM_activate(self, *args): - self._show_FSM_editor() comp_name = self._current_component() self._show_FSM_for_comp(comp_name) pass