fix: Android input after sending message

This commit is contained in:
Alan Diwix 2021-05-13 10:48:05 +00:00 committed by Krille Fear
parent 6c876ab2ac
commit 4488520f06
1 changed files with 4 additions and 1 deletions

View File

@ -202,7 +202,10 @@ class ChatController extends State<Chat> {
if (sendController.text.trim().isEmpty) return;
room.sendTextEvent(sendController.text,
inReplyTo: replyEvent, editEventId: editEvent?.eventId);
sendController.text = pendingText;
sendController.value = TextEditingValue(
text: pendingText,
selection: TextSelection.collapsed(offset: 0),
);
setState(() {
inputText = pendingText;