comparison libervia.tac @ 179:8475a29d7214

closing a group chat widget now leave the muc room (bug 11)
author Goffi <goffi@goffi.org>
date Sat, 26 Jan 2013 00:36:57 +0100
parents 631556a64850
children aa76793da353
comparison
equal deleted inserted replaced
178:7a349be99a77 179:8475a29d7214
266 room_jid = JID(room_jid) 266 room_jid = JID(room_jid)
267 except: 267 except:
268 warning('Invalid room jid') 268 warning('Invalid room jid')
269 return 269 return
270 self.sat_host.bridge.joinMUC(room_jid.userhost(), nick, {}, profile) 270 self.sat_host.bridge.joinMUC(room_jid.userhost(), nick, {}, profile)
271
272 def jsonrpc_mucLeave(self, room_jid):
273 """Quit a Multi-User Chat room"""
274 profile = ISATSession(self.session).profile
275 try:
276 room_jid = JID(room_jid)
277 except:
278 warning('Invalid room jid')
279 return
280 self.sat_host.bridge.mucLeave(room_jid.userhost(), profile)
271 281
272 def jsonrpc_getRoomsJoined(self): 282 def jsonrpc_getRoomsJoined(self):
273 """Return list of room already joined by user""" 283 """Return list of room already joined by user"""
274 profile = ISATSession(self.session).profile 284 profile = ISATSession(self.session).profile
275 return self.sat_host.bridge.getRoomsJoined(profile) 285 return self.sat_host.bridge.getRoomsJoined(profile)