# HG changeset patch # User Thinker K.F. Li # Date 1295509980 -28800 # Node ID 2aa3770f02bf6c0e6d577f66f5bdf72ab712731e # Parent cc557ce8e9fa0afaa53fb20c14abac3439c91236 Fix issue of events for setting cursor of treeview. - comp_dock_base.refresh() would set cursor, it cause an event. But, we don't want it. - The reason of the issue is that MBScene.show() is not monitored. So, we monitor it by move its body to do_show(). diff -r cc557ce8e9fa -r 2aa3770f02bf pyink/MBScene.py --- a/pyink/MBScene.py Thu Jan 20 15:35:56 2011 +0800 +++ b/pyink/MBScene.py Thu Jan 20 15:53:00 2011 +0800 @@ -354,7 +354,7 @@ self.addTweenTypeSelector(hbox) pass - def show(self): + def do_show(self): self.OK = True if not self._root: self._root = self.desktop.doc().root().repr @@ -387,4 +387,8 @@ self.top.show_all() self.last_update = None return False + + def show(self): + self.do_show() + pass pass diff -r cc557ce8e9fa -r 2aa3770f02bf pyink/comp_dock.py --- a/pyink/comp_dock.py Thu Jan 20 15:35:56 2011 +0800 +++ b/pyink/comp_dock.py Thu Jan 20 15:53:00 2011 +0800 @@ -139,6 +139,8 @@ self._locker = domview_ui pass + ## \brief Start handle UI events. + # def start_handle_ui_events(self): self._builder.connect_signals(self) pass @@ -266,7 +268,7 @@ class comp_dock(comp_dock_base, comp_dock_ui): def __init__(self, domview_ui, fname=None): super(comp_dock, self).__init__(domview_ui, fname) - + self.start_handle_ui_events() pass pass