directly send voice message instead of just attach

This commit is contained in:
12aw 2024-01-14 11:42:39 +01:00
parent 239f7d824d
commit f56cfe53d9
3 changed files with 5 additions and 5 deletions

View file

@ -3218,10 +3218,10 @@ public class ConversationFragment extends XmppFragment
() -> { () -> {
activity.setResult( activity.setResult(
Activity.RESULT_OK, new Intent().setData(Uri.fromFile(outputFile))); Activity.RESULT_OK, new Intent().setData(Uri.fromFile(outputFile)));
mediaPreviewAdapter.addMediaPreviews(Attachment.of(getActivity(), Uri.fromFile(outputFile), Attachment.Type.RECORDING)); //mediaPreviewAdapter.addMediaPreviews(Attachment.of(getActivity(), Uri.fromFile(outputFile), Attachment.Type.RECORDING));
toggleInputMethod(); //toggleInputMethod();
attachFileToConversation(conversation, Uri.fromFile(outputFile), "audio/mp4");
binding.recordingVoiceActivity.setVisibility(View.GONE); binding.recordingVoiceActivity.setVisibility(View.GONE);
//attachFileToConversation(conversation, Uri.fromFile(outputFile), "audio/mp4");
}); });
} }
} }

View file

@ -152,7 +152,7 @@
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:text="@string/attach" android:text="@string/send_now"
android:textColor="?attr/colorAccent" /> android:textColor="?attr/colorAccent" />
</LinearLayout> </LinearLayout>

View file

@ -153,7 +153,7 @@
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:text="@string/attach" android:text="@string/send_now"
android:textColor="?attr/colorAccent" /> android:textColor="?attr/colorAccent" />
</LinearLayout> </LinearLayout>