changeset a91c0ade3d9b in /home/hg/repos/gajim
details:http://hg.gajim.org/gajim?cmd=changeset;node=a91c0ade3d9b description: Fixed problem with multiple whiteboards and changed glade position numbers to fit in new button
diffstat:
data/glade/message_window.glade | 16 ++++++++-------- src/chat_control.py | 18 ++++++++++-------- 2 files changed, 18 insertions(+), 16 deletions(-)
diffs (110 lines):
diff -r 47338f8b413f -r a91c0ade3d9b data/glade/message_window.glade --- a/data/glade/message_window.glade Sun Jun 28 16:25:07 2009 +0200 +++ b/data/glade/message_window.glade Sun Jun 28 15:27:08 2009 -0700 @@ -353,7 +353,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">4</property> + <property name="position">5</property> </packing> </child> <child> @@ -377,7 +377,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">5</property> + <property name="position">6</property> </packing> </child> <child> @@ -401,7 +401,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">6</property> + <property name="position">7</property> </packing> </child> <child> @@ -425,7 +425,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">7</property> + <property name="position">8</property> </packing> </child> <child> @@ -436,7 +436,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">8</property> + <property name="position">9</property> </packing> </child> <child> @@ -460,7 +460,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">9</property> + <property name="position">10</property> </packing> </child> <child> @@ -472,7 +472,7 @@ </child> </widget> <packing> - <property name="position">10</property> + <property name="position">11</property> </packing> </child> <child> @@ -519,7 +519,7 @@ </widget> <packing> <property name="expand">False</property> - <property name="position">11</property> + <property name="position">12</property> </packing> </child> </widget> diff -r 47338f8b413f -r a91c0ade3d9b src/chat_control.py --- a/src/chat_control.py Sun Jun 28 16:25:07 2009 +0200 +++ b/src/chat_control.py Sun Jun 28 15:27:08 2009 -0700 @@ -294,8 +294,9 @@ # Hook up whiteboard button widget = self.xml.get_widget('start_whiteboard_button') - id_ = widget.connect('clicked', self._on_whiteboard_button_clicked) - self.handlers[id_] = widget + if widget is not None: + id_ = widget.connect('clicked', self._on_whiteboard_button_clicked) + self.handlers[id_] = widget def set_speller(self): try: @@ -2748,12 +2749,13 @@ self.print_conversation(')', 'status', simple=True) def _on_whiteboard_button_clicked(self, widget): - whiteboard = Whiteboard(gajim.connections[self.account]) hbox = self.xml.get_widget('chat_child_hbox') - try: - hbox.pack_start(whiteboard) - whiteboard.show() - except: - pass # TODO: Fix problem with groupchat? + if len(hbox.get_children()) == 1: + whiteboard = Whiteboard(gajim.connections[self.account]) + try: + hbox.pack_start(whiteboard) + whiteboard.show() + except: + pass # TODO: Fix problem with groupchat? # vim: se ts=3: