plugin text commands: refactoring, text now only contain main commands, and other plugin can add commands themselve:
- registerTextCommands can be called by a plugin in its __init__ method, it looks for methods starting with "cmd_" and register them as new commands
- addWhoIsCb: add a callback to /whois command, the callback can complete whois informations
- plugins parrot, XEP-0045 and XEP-0092 now manage their own commands
This commit is contained in:
parent
1339efa9f0
commit
8a52f6defa
1 changed files with 217 additions and 148 deletions
|
|
@ -36,3 +36,6 @@ class Const(object):
|
|||
PROF_KEY_NONE = '@NONE@'
|
||||
PROF_KEY_DEFAULT = '@DEFAULT@'
|
||||
IQ_SET = '/iq[@type="set"]'
|
||||
|
||||
# names of widely used plugins
|
||||
TEXT_CMDS = 'TEXT-COMMANDS'
|
||||
|
|
|
|||
Loading…
Reference in a new issue