diff options
author | mathieui <mathieui@mathieui.net> | 2011-11-13 14:34:45 +0100 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2011-11-13 14:34:45 +0100 |
commit | 98c342c1d4407d9e630e6bc5b4e5a24e6c4ac42d (patch) | |
tree | c10b873d22481c02711b6025064f2e8187f318e8 /src | |
parent | 30b9827a2766725f146a04bf00735748cde91fec (diff) | |
download | poezio-98c342c1d4407d9e630e6bc5b4e5a24e6c4ac42d.tar.gz poezio-98c342c1d4407d9e630e6bc5b4e5a24e6c4ac42d.tar.bz2 poezio-98c342c1d4407d9e630e6bc5b4e5a24e6c4ac42d.tar.xz poezio-98c342c1d4407d9e630e6bc5b4e5a24e6c4ac42d.zip |
Completion for /version
Diffstat (limited to 'src')
-rw-r--r-- | src/core.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/core.py b/src/core.py index 751b21f1..330d3d73 100644 --- a/src/core.py +++ b/src/core.py @@ -126,7 +126,7 @@ class Core(object): 'theme': (self.command_theme, _('Usage: /theme [theme_name]\nTheme: Reload the theme defined in the config file. If theme_name is provided, set that theme before reloading it.'), None), 'list': (self.command_list, _('Usage: /list\nList: Get the list of public chatrooms on the specified server.'), self.completion_list), 'message': (self.command_message, _('Usage: /message <jid> [optional message]\nMessage: Open a conversation with the specified JID (even if it is not in our roster), and send a message to it, if the message is specified.'), None), - 'version': (self.command_version, _('Usage: /version <jid>\nVersion: Get the software version of the given JID (usually its XMPP client and Operating System).'), None), + 'version': (self.command_version, _('Usage: /version <jid>\nVersion: Get the software version of the given JID (usually its XMPP client and Operating System).'), self.completion_version), 'connect': (self.command_reconnect, _('Usage: /connect\nConnect: Disconnect from the remote server if you are currently connected and then connect to it again.'), None), 'server_cycle': (self.command_server_cycle, _('Usage: /server_cycle [domain] [message]\nServer Cycle: Disconnect and reconnect in all the rooms in domain.'), None), 'bind': (self.command_bind, _('Usage: /bind <key> <equ>\nBind: Bind a key to an other key or to a “command”. For example "/bind ^H KEY_UP" makes Control + h do the same same as the Up key.'), None), @@ -1393,6 +1393,10 @@ class Core(object): the_input.auto_completion(serv_list, '') return True + def completion_version(self, the_input): + """Completion for /version""" + return the_input.auto_completion([contact.bare_jid for contact in roster.get_contacts()], '') + def completion_list(self, the_input): muc_serv_list = [] for tab in self.tabs: # TODO, also from an history |