Skip to content

Commit d52e6c8

Browse files
committed
fix jumping between search occurrences at the editor
1 parent 83e1322 commit d52e6c8

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

app/src/main/kotlin/com/simplemobiletools/filemanager/pro/activities/ReadTextActivity.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ class ReadTextActivity : SimpleActivity() {
9898
private fun openSearch() {
9999
isSearchActive = true
100100
search_wrapper.beVisible()
101-
102101
showKeyboard(searchQueryET)
103102

104103
read_text_view.requestFocus()
@@ -260,7 +259,7 @@ class ReadTextActivity : SimpleActivity() {
260259
read_text_view.text?.clearSpans()
261260

262261
if (text.isNotBlank() && text.length > 1) {
263-
searchMatches = text.searchMatches(read_text_view.value)
262+
searchMatches = read_text_view.value.searchMatches(text)
264263
read_text_view.highlightText(text, config.primaryColor)
265264
}
266265

0 commit comments

Comments
 (0)