Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Fomin <fominde@gmail.com>2010-11-03 22:15:17 +0300
committerDenis Fomin <fominde@gmail.com>2010-11-03 22:15:17 +0300
commite036cf91d371e40f5302bf721bfc1117fc364a26 (patch)
treeb7e9c2231c857b0759868d3d6fdafaa4fee710dd /plugins
parent08e00fffc265ca1826c271c43d6ca7248fc7b123 (diff)
whiteboard plugin. small optimization
Diffstat (limited to 'plugins')
-rw-r--r--plugins/whiteboard/plugin.py10
1 files changed, 4 insertions, 6 deletions
diff --git a/plugins/whiteboard/plugin.py b/plugins/whiteboard/plugin.py
index d81624908..8943618e0 100644
--- a/plugins/whiteboard/plugin.py
+++ b/plugins/whiteboard/plugin.py
@@ -341,12 +341,10 @@ class Base(object):
if not self.whiteboard:
return
hbox = self.chat_control.xml.get_object('chat_control_hbox')
- for child in hbox.get_children():
- if child == self.whiteboard.hbox:
- self.button.set_active(False)
- hbox.remove(child)
- self.whiteboard = None
- break
+ if self.whiteboard.hbox in hbox.get_children():
+ self.button.set_active(False)
+ hbox.remove(self.whiteboard.hbox)
+ self.whiteboard = None
def disconnect_from_chat_control(self):
actions_hbox = self.chat_control.xml.get_object('actions_hbox')