--- a/plugins/wb.admin/frontend/wb_admin_connections.py 2013-02-14 21:53:53.000000000 +0100 +++ b/plugins/wb.admin/frontend/wb_admin_connections.py 2013-03-07 10:55:49.674900277 +0100 @@ -15,7 +15,7 @@ # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA # 02110-1301 USA -from mforms import newTreeNodeView, newButton, newBox, newSelector, newLabel, Utilities +from mforms import newTreeNodeView, newButton, newBox, newSelector, newLabel, newCheckBox, Utilities import mforms from functools import partial @@ -101,6 +101,11 @@ class WbAdminConnections(mforms.Box): self.refresh_selector.set_selected(9) box.add(self.refresh_selector, False, True) self.refresh_selector.add_changed_callback(weakcb(self, "update_refresh_rate")) + + self.hide_sleep_checkbox = newCheckBox() + self.hide_sleep_checkbox.set_text("Hide sleeping connections") + box.add(self.hide_sleep_checkbox, False, True) + self.hide_sleep_checkbox.add_clicked_callback(weakcb(self, "refresh")) self.add(box, False, True) @@ -146,6 +151,8 @@ class WbAdminConnections(mforms.Box): if result is not None: result_rows = [] while result.nextRow(): + if result.stringByName("Command") == "Sleep" and self.hide_sleep_checkbox.get_active(): + continue row = [] for field in fields: value = result.stringByName(field)