diff libervia.py @ 146:d15fbb208ba0

browser side: fixed MUC signals management
author Goffi <goffi@goffi.org>
date Sun, 09 Dec 2012 23:37:20 +0100
parents a5e9aa1f9c0c
children 8635bc9db9bf
line wrap: on
line diff
--- a/libervia.py	Sun Dec 09 23:34:20 2012 +0100
+++ b/libervia.py	Sun Dec 09 23:37:20 2012 +0100
@@ -376,35 +376,35 @@
         chat_panel.setPresents(room_nicks)
         chat_panel.historyPrint()
 
-    def _roomUserJoinedCb(self, room_jid, user_nick, user_data):
+    def _roomUserJoinedCb(self, room_jid_s, user_nick, user_data):
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid.bare:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 lib_wid.userJoined(user_nick, user_data)
 
-    def _roomUserLeftCb(self, room_jid, user_nick, user_data):
+    def _roomUserLeftCb(self, room_jid_s, user_nick, user_data):
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid.bare:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 lib_wid.userLeft(user_nick, user_data)
         
-    def _tarotGameStartedCb(self, room_jid, referee, players):
+    def _tarotGameStartedCb(self, room_jid_s, referee, players):
         print ("Tarot Game Started \o/")
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 lib_wid.startGame("Tarot", referee, players)
 
-    def _tarotGameGenericCb(self, event_name, room_jid, args):
+    def _tarotGameGenericCb(self, event_name, room_jid_s, args):
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 getattr(lib_wid.getGame("Tarot"), event_name)(*args) 
 
-    def _radioColStartedCb(self, room_jid, referee):
+    def _radioColStartedCb(self, room_jid_s, referee):
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 lib_wid.startGame("RadioCol", referee)
     
-    def _radioColGenericCb(self, event_name, room_jid, args):
+    def _radioColGenericCb(self, event_name, room_jid_s, args):
         for lib_wid in self.libervia_widgets:
-            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid:
+            if isinstance(lib_wid,panels.ChatPanel) and lib_wid.type == 'group' and lib_wid.target.bare == room_jid_s:
                 getattr(lib_wid.getGame("RadioCol"), event_name)(*args)