Closed EmmanuelMess closed 2 years ago
Also works just fine on the sample. Can you check again if it is a bug of this library?
Sorry, not the back button, the up button. Got them confused.
Also doesn't work with back button on Android 11 with gestures enabled.
I think somewhere in your code you're refocusing the searchview.
You said you're programmatically focusing it, so check if it is being called after you click the up button.
Can you share the code around setSearchFocused
?
mainActivity.showSmokeScreen()
animator.interpolator = AccelerateDecelerateInterpolator()
animator.duration = 600
searchView.visibility = View.VISIBLE
animator.start()
animator.addListener(
object : AnimatorListenerAdapter() {
override fun onAnimationEnd(animation: Animator) {
searchView.setSearchFocused(true)
isEnabled = true
}
})
yea, you can print something in onAnimationEnd to see if it is being called
Or better, just remove the setSearchFocused call and try to see it fixes anything
yea, you can print something in onAnimationEnd to see if it is being called
That code sets the view as focused, AFAIK the keyboard doesnt show otherwise. I have no code hiding the keyboard explicitly.
Just tested, without the focus set the keyboard will not open.
close_search_on_keyboard_dismiss
is working as intended. What it does is it clears the focus when the keyboard is closed, nothing more. You need to add the code to close the view. You can use FloatingSearchView.onFocusChangeListener
to listen to focus events.
"close_search_on_keyboard_dismiss" isn't working.
To show the keyboard I use
searchView.setSearchFocused(true)
and to close it I tap on the "back" icon, but I have to tap twice.