Fix an issue #450

This commit is contained in:
Thomas 2022-11-13 18:33:34 +01:00
parent f78184216d
commit 966b0bce43
1 changed files with 3 additions and 0 deletions

View File

@ -920,6 +920,7 @@ public class ComposeAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
holder.binding.content.setText(newContent); holder.binding.content.setText(newContent);
updateCharacterCount(holder); updateCharacterCount(holder);
holder.binding.content.setSelection(newPosition); holder.binding.content.setSelection(newPosition);
statusList.get(holder.getBindingAdapterPosition()).text = newContent;
AccountsSearchAdapter accountsListAdapter1 = new AccountsSearchAdapter(context, new ArrayList<>()); AccountsSearchAdapter accountsListAdapter1 = new AccountsSearchAdapter(context, new ArrayList<>());
holder.binding.content.setThreshold(1); holder.binding.content.setThreshold(1);
holder.binding.content.setAdapter(accountsListAdapter1); holder.binding.content.setAdapter(accountsListAdapter1);
@ -972,6 +973,7 @@ public class ComposeAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
if (currentCursorPosition < oldContent.length()) if (currentCursorPosition < oldContent.length())
newContent += oldContent.substring(currentCursorPosition); newContent += oldContent.substring(currentCursorPosition);
holder.binding.content.setText(newContent); holder.binding.content.setText(newContent);
statusList.get(holder.getBindingAdapterPosition()).text = newContent;
updateCharacterCount(holder); updateCharacterCount(holder);
holder.binding.content.setSelection(newPosition); holder.binding.content.setSelection(newPosition);
TagsSearchAdapter tagsSearchAdapter1 = new TagsSearchAdapter(context, new ArrayList<>()); TagsSearchAdapter tagsSearchAdapter1 = new TagsSearchAdapter(context, new ArrayList<>());
@ -1030,6 +1032,7 @@ public class ComposeAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
if (currentCursorPosition < oldContent.length()) if (currentCursorPosition < oldContent.length())
newContent += oldContent.substring(currentCursorPosition); newContent += oldContent.substring(currentCursorPosition);
holder.binding.content.setText(newContent); holder.binding.content.setText(newContent);
statusList.get(holder.getBindingAdapterPosition()).text = newContent;
updateCharacterCount(holder); updateCharacterCount(holder);
holder.binding.content.setSelection(newPosition); holder.binding.content.setSelection(newPosition);
EmojiSearchAdapter emojisSearchAdapter1 = new EmojiSearchAdapter(context, new ArrayList<>()); EmojiSearchAdapter emojisSearchAdapter1 = new EmojiSearchAdapter(context, new ArrayList<>());