prevent traceback when a whiteboard closes

This commit is contained in:
Denis Fomin 2010-11-04 14:49:58 +03:00
parent 96c02c67b4
commit e7cfc9f2f7
1 changed files with 3 additions and 2 deletions

View File

@ -343,8 +343,9 @@ class Base(object):
hbox = self.chat_control.xml.get_object('chat_control_hbox')
if self.whiteboard.hbox in hbox.get_children():
self.button.set_active(False)
hbox.remove(self.whiteboard.hbox)
self.whiteboard = None
if hasattr(self.whiteboard, 'hbox'):
hbox.remove(self.whiteboard.hbox)
self.whiteboard = None
def disconnect_from_chat_control(self):
actions_hbox = self.chat_control.xml.get_object('actions_hbox')