diff options
author | iNPUTmice <daniel@gultsch.de> | 2014-08-13 11:21:33 +0200 |
---|---|---|
committer | iNPUTmice <daniel@gultsch.de> | 2014-08-13 11:21:33 +0200 |
commit | a4faa158c0c8f92f9f430c8daa931f16b4f2a58d (patch) | |
tree | 98614df82ccca52831e8ff24d4dcaecac2618aa7 /src/eu | |
parent | 07e6873025a29df6ab3d9597c9f0457616add55a (diff) |
only notify ui on significant muc changes
Diffstat (limited to 'src/eu')
-rw-r--r-- | src/eu/siacs/conversations/parser/PresenceParser.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/eu/siacs/conversations/parser/PresenceParser.java b/src/eu/siacs/conversations/parser/PresenceParser.java index 3582653fa..ea19df6f7 100644 --- a/src/eu/siacs/conversations/parser/PresenceParser.java +++ b/src/eu/siacs/conversations/parser/PresenceParser.java @@ -24,16 +24,23 @@ public class PresenceParser extends AbstractParser implements Conversation muc = mXmppConnectionService.find(account, packet .getAttribute("from").split("/")[0]); if (muc != null) { + boolean before = muc.getMucOptions().online(); muc.getMucOptions().processPacket(packet, mPgpEngine); + if (before!=muc.getMucOptions().online()) { + mXmppConnectionService.updateConversationUi(); + } } } else if (packet.hasChild("x", "http://jabber.org/protocol/muc")) { Conversation muc = mXmppConnectionService.find(account, packet .getAttribute("from").split("/")[0]); if (muc != null) { + boolean before = muc.getMucOptions().online(); muc.getMucOptions().processPacket(packet, mPgpEngine); + if (before!=muc.getMucOptions().online()) { + mXmppConnectionService.updateConversationUi(); + } } } - mXmppConnectionService.updateConversationUi(); } public void parseContactPresence(PresencePacket packet, Account account) { |