diff options
Diffstat (limited to 'src/eu/siacs/conversations/entities/MucOptions.java')
-rw-r--r-- | src/eu/siacs/conversations/entities/MucOptions.java | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/eu/siacs/conversations/entities/MucOptions.java b/src/eu/siacs/conversations/entities/MucOptions.java index b3b53e1d..add56fb6 100644 --- a/src/eu/siacs/conversations/entities/MucOptions.java +++ b/src/eu/siacs/conversations/entities/MucOptions.java @@ -3,6 +3,7 @@ package eu.siacs.conversations.entities; import java.util.ArrayList; import java.util.List; +import eu.siacs.conversations.entities.MucOptions.User; import eu.siacs.conversations.xml.Element; import eu.siacs.conversations.xmpp.PresencePacket; import android.annotation.SuppressLint; @@ -75,6 +76,7 @@ public class MucOptions { private boolean isOnline = false; private int error = 0; private OnRenameListener renameListener = null; + private User self = new User(); public void deleteUser(String name) { @@ -107,12 +109,14 @@ public class MucOptions { user.setAffiliation(item.getAttribute("affiliation")); user.setRole(item.getAttribute("role")); user.setName(name); - addUser(user); Log.d("xmppService","nick: "+getNick()); Log.d("xmppService","name: "+name); if (name.equals(getNick())) { this.isOnline = true; this.error = 0; + self = user; + } else { + addUser(user); } } else if (type.equals("unavailable")) { Log.d("xmppService","name: "+name); @@ -179,4 +183,8 @@ public class MucOptions { this.error = 0; this.isOnline = false; } + + public User getSelf() { + return self; + } }
\ No newline at end of file |