mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-22 20:12:07 +01:00
SMACK-312 Fire roster listener also when the group name changed
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@12087 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
5a544a50e3
commit
4ada4978d8
1 changed files with 5 additions and 3 deletions
|
@ -854,9 +854,11 @@ public class Roster {
|
|||
// If the entry was in then list then update its state with the new values
|
||||
RosterEntry oldEntry = entries.put(item.getUser(), entry);
|
||||
|
||||
// Keep note that an entry has been updated but only if it's different
|
||||
if (oldEntry == null || !oldEntry.equalsDeep(entry)) {
|
||||
updatedEntries.add(item.getUser());
|
||||
RosterPacket.Item oldItem = RosterEntry.toRosterItem(oldEntry);
|
||||
//We have also to check if only the group names have changed from the item
|
||||
if (oldEntry == null || !oldEntry.equalsDeep(entry) || !item.getGroupNames().equals(oldItem.getGroupNames()))
|
||||
{
|
||||
updatedEntries.add(item.getUser());
|
||||
}
|
||||
}
|
||||
// If the roster entry belongs to any groups, remove it from the
|
||||
|
|
Loading…
Reference in a new issue