plugin XEP-0085: Chat State Notifications
- new "options" parameter to send chat states
- plugin command export: messages without body are now delivered (since all the chat states other than "active" need them)
This commit is contained in:
parent
174a0d9862
commit
9cb7071e89
2 changed files with 368 additions and 33 deletions
|
|
@ -385,10 +385,10 @@ class DbusObject(dbus.service.Object):
|
|||
return self._callback("registerNewAccount", unicode(login), unicode(password), unicode(email), unicode(host), port)
|
||||
|
||||
@dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX,
|
||||
in_signature='sssss', out_signature='',
|
||||
in_signature='ssssa{ss}s', out_signature='',
|
||||
async_callbacks=None)
|
||||
def sendMessage(self, to_jid, message, subject='', mess_type="auto", profile_key="@DEFAULT@"):
|
||||
return self._callback("sendMessage", unicode(to_jid), unicode(message), unicode(subject), unicode(mess_type), unicode(profile_key))
|
||||
def sendMessage(self, to_jid, message, subject='', mess_type="auto", options={}, profile_key="@NONE@"):
|
||||
return self._callback("sendMessage", unicode(to_jid), unicode(message), unicode(subject), unicode(mess_type), options, unicode(profile_key))
|
||||
|
||||
@dbus.service.method(const_INT_PREFIX+const_CORE_SUFFIX,
|
||||
in_signature='ssss', out_signature='',
|
||||
|
|
|
|||
|
|
@ -344,17 +344,19 @@ doc_return=List of confirmation request data, same as for [askConfirmation]
|
|||
[sendMessage]
|
||||
type=method
|
||||
category=core
|
||||
sig_in=sssss
|
||||
sig_in=ssssa{ss}s
|
||||
sig_out=
|
||||
param_2_default=''
|
||||
param_3_default="auto"
|
||||
param_4_default="@DEFAULT@"
|
||||
param_4_default={}
|
||||
param_5_default="@NONE@"
|
||||
doc=Send a message
|
||||
doc_param_0=to_jid: JID of the recipient
|
||||
doc_param_1=message: body of the message
|
||||
doc_param_2=subject: Subject of the message ('' if no subject)
|
||||
doc_param_3=mess_type: Type of the message (cf RFC 3921 #2.1.1) or "auto" for automatic type detection
|
||||
doc_param_4=%(doc_profile_key)s
|
||||
doc_param_4=options: optional data that can be used by a plugin to build more specific messages
|
||||
doc_param_5=%(doc_profile_key)s
|
||||
|
||||
[setPresence]
|
||||
type=method
|
||||
|
|
|
|||
Loading…
Reference in a new issue