# HG changeset patch # User souliane # Date 1425648169 -3600 # Node ID 56c14cb29e0f896200a02237f0ea473f5ff87029 # Parent ec43552f5f8b220cb45722576969a3d45473c290 quick_frontend: register the 'personalEvent' signal diff -r ec43552f5f8b -r 56c14cb29e0f frontends/src/quick_frontend/quick_app.py --- a/frontends/src/quick_frontend/quick_app.py Thu Mar 05 13:48:49 2015 +0100 +++ b/frontends/src/quick_frontend/quick_app.py Fri Mar 06 14:22:49 2015 +0100 @@ -269,6 +269,7 @@ self.registerSignal("quizGameTimerExpired", iface="plugin") self.registerSignal("quizGameTimerRestarted", iface="plugin") self.registerSignal("chatStateReceived", iface="plugin") + self.registerSignal("personalEvent", iface="plugin") self.current_action_ids = set() # FIXME: to be removed self.current_action_ids_cb = {} # FIXME: to be removed @@ -688,6 +689,16 @@ if from_jid == C.ENTITY_ALL or from_jid.bare == widget.target.bare: widget.updateChatState(from_jid, state) + def personalEventHandler(self, sender, event_type, data): + """Called when a PEP event is received. + + @param sender (jid.JID): event sender + @param event_type (unicode): event type, e.g. 'MICROBLOG' or 'MICROBLOG_DELETE' + @param data (dict): event data + """ + # FIXME move some code from Libervia to here and put the magic strings to constants + pass + def _subscribe_cb(self, answer, data): entity, profile = data type_ = "subscribed" if answer else "unsubscribed"