aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorChristian Schneppe <christian@pix-art.de>2017-10-18 21:21:38 +0200
committerChristian Schneppe <christian@pix-art.de>2017-10-18 21:21:38 +0200
commita5bfed5cc1c526fa12dd7e60731f106837918d86 (patch)
treecd4bc653a950b9bcb53a58fd225133771e7f70c4 /src/main/java
parentbbd443445876e916ed66c4e7ba385608cdac4f84 (diff)
bring back option to highlight user in muc ...
... via context menu on selected user in ConferenceDetails
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/de/pixart/messenger/ui/ConferenceDetailsActivity.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/de/pixart/messenger/ui/ConferenceDetailsActivity.java b/src/main/java/de/pixart/messenger/ui/ConferenceDetailsActivity.java
index 77f571433..134f82a5e 100644
--- a/src/main/java/de/pixart/messenger/ui/ConferenceDetailsActivity.java
+++ b/src/main/java/de/pixart/messenger/ui/ConferenceDetailsActivity.java
@@ -388,13 +388,14 @@ public class ConferenceDetailsActivity extends XmppActivity implements OnConvers
final Contact contact = user.getContact();
if (contact != null) {
name = contact.getDisplayName();
- } else if (user.getRealJid() != null) {
+ } else if (user.getRealJid() != null){
name = user.getRealJid().toBareJid().toString();
} else {
name = user.getName();
}
menu.setHeaderTitle(name);
if (user.getRealJid() != null) {
+ MenuItem highlightInMuc = menu.findItem(R.id.highlight_in_muc);
MenuItem startConversation = menu.findItem(R.id.start_conversation);
MenuItem giveMembership = menu.findItem(R.id.give_membership);
MenuItem removeMembership = menu.findItem(R.id.remove_membership);
@@ -403,6 +404,7 @@ public class ConferenceDetailsActivity extends XmppActivity implements OnConvers
MenuItem removeFromRoom = menu.findItem(R.id.remove_from_room);
MenuItem banFromConference = menu.findItem(R.id.ban_from_conference);
MenuItem invite = menu.findItem(R.id.invite);
+ highlightInMuc.setVisible(true);
startConversation.setVisible(true);
if (user.getRole() == MucOptions.Role.NONE) {
invite.setVisible(true);
@@ -438,6 +440,9 @@ public class ConferenceDetailsActivity extends XmppActivity implements OnConvers
public boolean onContextItemSelected(MenuItem item) {
Jid jid = mSelectedUser.getRealJid();
switch (item.getItemId()) {
+ case R.id.highlight_in_muc:
+ highlightInMuc(mConversation, mSelectedUser.getName());
+ return true;
case R.id.start_conversation:
startConversation(mSelectedUser);
return true;