Skip to content

Commit 526bf74

Browse files
dbrantWilliamrai
andauthored
Place cursor at end of string when editing description. (#6175)
Co-authored-by: William Rai <[email protected]>
1 parent b620379 commit 526bf74

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

app/src/main/java/org/wikipedia/descriptions/DescriptionEditView.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,9 @@ class DescriptionEditView(context: Context, attrs: AttributeSet?) : LinearLayout
6666
get() = binding.viewDescriptionEditText.text.toString().trim()
6767
set(text) {
6868
binding.viewDescriptionEditText.setText(text)
69+
if (!text.isNullOrEmpty()) {
70+
binding.viewDescriptionEditText.setSelection(text.length)
71+
}
6972
}
7073

7174
init {

0 commit comments

Comments
 (0)