aboutsummaryrefslogtreecommitdiff
path: root/sample/src/main/kotlin
diff options
context:
space:
mode:
Diffstat (limited to 'sample/src/main/kotlin')
-rw-r--r--sample/src/main/kotlin/ca/allanwang/kau/sample/MainActivity.kt5
1 files changed, 5 insertions, 0 deletions
diff --git a/sample/src/main/kotlin/ca/allanwang/kau/sample/MainActivity.kt b/sample/src/main/kotlin/ca/allanwang/kau/sample/MainActivity.kt
index 93fc651..5d0bd36 100644
--- a/sample/src/main/kotlin/ca/allanwang/kau/sample/MainActivity.kt
+++ b/sample/src/main/kotlin/ca/allanwang/kau/sample/MainActivity.kt
@@ -230,6 +230,11 @@ class MainActivity : KPrefActivity() {
val items = wordBank.filter { it.contains(query) }.sorted().map { SearchItem(it) }
searchView.results = items
}
+ searchCallback = {
+ query, _ ->
+ toast("Enter pressed for $query")
+ true
+ }
textDebounceInterval = 0
noResultsFound = R.string.kau_no_results_found
shouldClearOnClose = false