Browse Source

Merge pull request #3021 from nextcloud/bugfix/fixChatActivityInstance

fix multiple bugs caused by launchMode="singleInstance" and noHistory="true"
Marcel Hibbe 2 years ago
parent
commit
ab4ce8c4e4

+ 0 - 2
app/src/main/AndroidManifest.xml

@@ -211,8 +211,6 @@
 
         <activity
             android:name=".chat.ChatActivity"
-            android:launchMode="singleInstance"
-            android:noHistory="true"
             android:screenOrientation="portrait"
             android:theme="@style/AppTheme" />
 

+ 3 - 1
app/src/main/java/com/nextcloud/talk/chat/ChatActivity.kt

@@ -542,7 +542,9 @@ class ChatActivity :
 
         initVoiceRecordButton()
 
-        binding?.messageInputView?.inputEditText?.setText(sharedText)
+        if (sharedText.isNotEmpty()) {
+            binding?.messageInputView?.inputEditText?.setText(sharedText)
+        }
         binding?.messageInputView?.setAttachmentsListener {
             AttachmentDialog(this, this).show()
         }