dynamicreconfig-hg
changeset 256:639642f1fce5
Fix #4640 don't trigger update on page change.
| author | Ze'ev Klapow <zklapow@willowgarage.com> |
|---|---|
| date | Fri Jun 22 09:43:56 2012 -0700 (12 months ago) |
| parents | 305a8013a01d |
| children | a7ce24ebad69 |
| files | reconfigure_gui/src/reconfigure_gui/reconfigure_widget.py reconfigure_gui/src/reconfigure_gui/updater.py |
line diff
1.1 --- a/reconfigure_gui/src/reconfigure_gui/reconfigure_widget.py Thu Jun 21 18:00:17 2012 -0700 1.2 +++ b/reconfigure_gui/src/reconfigure_gui/reconfigure_widget.py Fri Jun 22 09:43:56 2012 -0700 1.3 @@ -73,6 +73,7 @@ 1.4 1.5 self.parent = parent 1.6 self.last_nodes = None 1.7 + self.current_node = '' 1.8 1.9 self.combo = QComboBox(self) 1.10 self.update_combo() 1.11 @@ -112,7 +113,9 @@ 1.12 self.last_nodes = nodes 1.13 1.14 def selected(self, node): 1.15 - self.parent.show(node) 1.16 + if not node == self.current_node: 1.17 + self.parent.show(node) 1.18 + self.current_node = node 1.19 1.20 class ClientWidget(Group): 1.21 def __init__(self, reconf):
2.1 --- a/reconfigure_gui/src/reconfigure_gui/updater.py Thu Jun 21 18:00:17 2012 -0700 2.2 +++ b/reconfigure_gui/src/reconfigure_gui/updater.py Fri Jun 22 09:43:56 2012 -0700 2.3 @@ -22,7 +22,10 @@ 2.4 if last_commit >= self._last_pending: 2.5 with self._cv: 2.6 self._cv.wait() 2.7 - 2.8 + 2.9 + if self._stop_flag: 2.10 + return 2.11 + 2.12 last_commit = time.time() 2.13 update = self._pending_config.copy() 2.14 self._pending_config = {}
