aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-06-26 12:09:12 +0200
committeriNPUTmice <daniel@gultsch.de>2014-06-26 12:09:12 +0200
commit3bb585c020f6b21e41de7ce6d8ee9cb0675a9b54 (patch)
treeb5449dccd4f885a1340eebcbfb78d21f8793a901
parent513b3959dcb60dff5b0c176fab4824c0263eeff1 (diff)
fixed rare bug with attach image menu
-rw-r--r--src/eu/siacs/conversations/ui/ConversationActivity.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/ui/ConversationActivity.java b/src/eu/siacs/conversations/ui/ConversationActivity.java
index 1e806d31d..d48367194 100644
--- a/src/eu/siacs/conversations/ui/ConversationActivity.java
+++ b/src/eu/siacs/conversations/ui/ConversationActivity.java
@@ -461,6 +461,9 @@ public class ConversationActivity extends XmppActivity {
break;
case R.id.action_attach_file:
View menuAttachFile = findViewById(R.id.action_attach_file);
+ if (menuAttachFile==null) {
+ break;
+ }
PopupMenu attachFilePopup = new PopupMenu(this, menuAttachFile);
attachFilePopup.inflate(R.menu.attachment_choices);
attachFilePopup
@@ -519,6 +522,9 @@ public class ConversationActivity extends XmppActivity {
case R.id.action_security:
final Conversation conversation = getSelectedConversation();
View menuItemView = findViewById(R.id.action_security);
+ if (menuItemView==null) {
+ break;
+ }
PopupMenu popup = new PopupMenu(this, menuItemView);
final ConversationFragment fragment = (ConversationFragment) getFragmentManager()
.findFragmentByTag("conversation");