summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2011-09-20 01:27:57 +0200
committermathieui <mathieui@mathieui.net>2011-09-20 01:27:57 +0200
commit6ec1ca42cc8bb55adaa3bf5df40cdabb5f2dd5f5 (patch)
tree5f5f57458744d436e03a14a88659f2b37d7c17e3 /src
parenta3b8452358067796588cb073b586c5e010aff938 (diff)
downloadpoezio-6ec1ca42cc8bb55adaa3bf5df40cdabb5f2dd5f5.tar.gz
poezio-6ec1ca42cc8bb55adaa3bf5df40cdabb5f2dd5f5.tar.bz2
poezio-6ec1ca42cc8bb55adaa3bf5df40cdabb5f2dd5f5.tar.xz
poezio-6ec1ca42cc8bb55adaa3bf5df40cdabb5f2dd5f5.zip
Fixes #2221
Diffstat (limited to 'src')
-rw-r--r--src/tabs.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/tabs.py b/src/tabs.py
index 7e535682..26f8bd0e 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -999,11 +999,12 @@ class PrivateTab(ChatTab):
# keys
self.key_func['^I'] = self.completion
# commands
- #self.commands['info'] = (self.command_info, _('Usage: /info\nInfo: Display some information about the user in the MUC: '), None)
+ self.commands['info'] = (self.command_info, _('Usage: /info\nInfo: Display some information about the user in the MUC: '), None)
self.commands['unquery'] = (self.command_unquery, _("Usage: /unquery\nUnquery: close the tab"), None)
self.commands['part'] = (self.command_unquery, _("Usage: /part\nPart: close the tab"), None)
self.commands['version'] = (self.command_version, _('Usage: /version\nVersion: get the software version of the current interlocutor (usually its XMPP client and Operating System)'), None)
self.resize()
+ self.parent_muc = self.core.get_tab_by_name(JID(room.name).bare, MucTab)
self.on = True
def completion(self):
@@ -1049,6 +1050,16 @@ class PrivateTab(ChatTab):
jid = self.get_room().name
self.core.xmpp.plugin['xep_0092'].get_version(jid, callback=callback)
+ def command_info(self, arg):
+ """
+ /info
+ """
+ if arg:
+ self.parent_muc.command_info(arg)
+ else:
+ user = JID(self.get_room().name).resource
+ self.parent_muc.command_info(user)
+
def resize(self):
if self.core.information_win_size >= self.height-3 or not self.visible:
return