fixed rare bug with attach image menu
This commit is contained in:
parent
513b3959dc
commit
3bb585c020
|
@ -461,6 +461,9 @@ public class ConversationActivity extends XmppActivity {
|
||||||
break;
|
break;
|
||||||
case R.id.action_attach_file:
|
case R.id.action_attach_file:
|
||||||
View menuAttachFile = findViewById(R.id.action_attach_file);
|
View menuAttachFile = findViewById(R.id.action_attach_file);
|
||||||
|
if (menuAttachFile==null) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
PopupMenu attachFilePopup = new PopupMenu(this, menuAttachFile);
|
PopupMenu attachFilePopup = new PopupMenu(this, menuAttachFile);
|
||||||
attachFilePopup.inflate(R.menu.attachment_choices);
|
attachFilePopup.inflate(R.menu.attachment_choices);
|
||||||
attachFilePopup
|
attachFilePopup
|
||||||
|
@ -519,6 +522,9 @@ public class ConversationActivity extends XmppActivity {
|
||||||
case R.id.action_security:
|
case R.id.action_security:
|
||||||
final Conversation conversation = getSelectedConversation();
|
final Conversation conversation = getSelectedConversation();
|
||||||
View menuItemView = findViewById(R.id.action_security);
|
View menuItemView = findViewById(R.id.action_security);
|
||||||
|
if (menuItemView==null) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
PopupMenu popup = new PopupMenu(this, menuItemView);
|
PopupMenu popup = new PopupMenu(this, menuItemView);
|
||||||
final ConversationFragment fragment = (ConversationFragment) getFragmentManager()
|
final ConversationFragment fragment = (ConversationFragment) getFragmentManager()
|
||||||
.findFragmentByTag("conversation");
|
.findFragmentByTag("conversation");
|
||||||
|
|
Loading…
Reference in a new issue