mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-03-17 11:48:51 +03:00
updating comment to mention the cursor position
This commit is contained in:
parent
cc9fb326dd
commit
7b691cc433
1 changed files with 1 additions and 1 deletions
|
@ -181,7 +181,7 @@ class AutoCompleter @AssistedInject constructor(
|
|||
.with(backgroundDrawable)
|
||||
.with(object : AutocompleteCallback<String> {
|
||||
override fun onPopupItemClicked(editable: Editable, item: String): Boolean {
|
||||
// Detect last ":" and remove it
|
||||
// Infer that the last ":" before the current cursor position is the original popup trigger
|
||||
var startIndex = editable.subSequence(0, editText.selectionStart).lastIndexOf(":")
|
||||
if (startIndex == -1) {
|
||||
startIndex = 0
|
||||
|
|
Loading…
Add table
Reference in a new issue