comparison src/plugins/plugin_exp_parrot.py @ 697:0c84fb112d70

core: sendMessage triggers now use a treatments deferred; - treaments deferred can be used by plugins to change XML elements before sending them, in a similar way as for newMessage - sendMessageXml trigger became useless, so it as been removed in favor of the new deferred
author Goffi <goffi@goffi.org>
date Wed, 13 Nov 2013 13:57:36 +0100
parents 8004c7d4aba7
children bfabeedbf32e
comparison
equal deleted inserted replaced
696:f1a2831d549d 697:0c84fb112d70
46 info(_("Plugin Parrot initialization")) 46 info(_("Plugin Parrot initialization"))
47 self.host = host 47 self.host = host
48 host.trigger.add("MessageReceived", self.MessageReceivedTrigger, priority=100) 48 host.trigger.add("MessageReceived", self.MessageReceivedTrigger, priority=100)
49 #host.trigger.add("sendMessage", self.sendMessageTrigger, priority=100) 49 #host.trigger.add("sendMessage", self.sendMessageTrigger, priority=100)
50 50
51 #def sendMessageTrigger(self, mess_data, profile): 51 #def sendMessageTrigger(self, mess_data, treatments, profile):
52 # """ Deactivate other triggers if recipient is in parrot links """ 52 # """ Deactivate other triggers if recipient is in parrot links """
53 # client = self.host.getClient(profile) 53 # client = self.host.getClient(profile)
54 # try: 54 # try:
55 # _links = client.parrot_links 55 # _links = client.parrot_links
56 # except AttributeError: 56 # except AttributeError: