diff options
Diffstat (limited to 'src/main/java/de/pixart')
3 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/de/pixart/messenger/entities/MucOptions.java b/src/main/java/de/pixart/messenger/entities/MucOptions.java index 27b318f0c..47ca622fc 100644 --- a/src/main/java/de/pixart/messenger/entities/MucOptions.java +++ b/src/main/java/de/pixart/messenger/entities/MucOptions.java @@ -139,6 +139,7 @@ public class MucOptions { PASSWORD_REQUIRED, BANNED, MEMBERS_ONLY, + RESOURCE_CONSTRAINT, KICKED, SHUTDOWN, INVALID_NICK, diff --git a/src/main/java/de/pixart/messenger/parser/PresenceParser.java b/src/main/java/de/pixart/messenger/parser/PresenceParser.java index f3ca0e747..3b6b83fd4 100644 --- a/src/main/java/de/pixart/messenger/parser/PresenceParser.java +++ b/src/main/java/de/pixart/messenger/parser/PresenceParser.java @@ -162,6 +162,8 @@ public class PresenceParser extends AbstractParser implements mucOptions.setError(MucOptions.Error.BANNED); } else if (error.hasChild("registration-required")) { mucOptions.setError(MucOptions.Error.MEMBERS_ONLY); + } else if (error.hasChild("resource-constraint")) { + mucOptions.setError(MucOptions.Error.RESOURCE_CONSTRAINT); } else { final String text = error.findChildContent("text"); if (text != null && text.contains("attribute 'to'")) { diff --git a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java index a22b775b3..4ec01434d 100644 --- a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java +++ b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java @@ -2330,6 +2330,9 @@ public class ConversationFragment extends XmppFragment implements EditMessage.Ke case MEMBERS_ONLY: showSnackbar(R.string.conference_members_only, R.string.leave, leaveMuc); break; + case RESOURCE_CONSTRAINT: + showSnackbar(R.string.conference_resource_constraint, R.string.try_again, joinMuc); + break; case KICKED: showSnackbar(R.string.conference_kicked, R.string.join, joinMuc); break; |