aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/ui/ConversationFragment.java
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/eu/siacs/conversations/ui/ConversationFragment.java10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/eu/siacs/conversations/ui/ConversationFragment.java b/src/eu/siacs/conversations/ui/ConversationFragment.java
index 6e5105f5..55a0d1a5 100644
--- a/src/eu/siacs/conversations/ui/ConversationFragment.java
+++ b/src/eu/siacs/conversations/ui/ConversationFragment.java
@@ -115,6 +115,7 @@ public class ConversationFragment extends Fragment {
startActivity(intent);
}
};
+ private ConversationActivity activity;
public void hidePgpPassphraseBox() {
pgpInfo.setVisibility(View.GONE);
@@ -325,16 +326,21 @@ public class ConversationFragment extends Fragment {
@Override
public void onStart() {
super.onStart();
- ConversationActivity activity = (ConversationActivity) getActivity();
+ this.activity = (ConversationActivity) getActivity();
SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(activity);
this.useSubject = preferences.getBoolean("use_subject_in_muc", true);
if (activity.xmppConnectionServiceBound) {
this.onBackendConnected();
}
}
+
+ @Override
+ public void onResume() {
+ super.onResume();
+ activity.registerListener();
+ }
public void onBackendConnected() {
- final ConversationActivity activity = (ConversationActivity) getActivity();
activity.registerListener();
this.conversation = activity.getSelectedConversation();
if (this.conversation == null) {