[Android] Fix audio search state when in cover mode

Nicolas Pomepuy git at videolan.org
Mon Nov 7 15:03:26 UTC 2022


vlc-android | branch: master | Nicolas Pomepuy <nicolas at videolabs.io> | Mon Nov  7 13:52:44 2022 +0100| [148397549ca8cd172c1044a7c8f7ced4134659a7] | committer: Duncan McNamara

Fix audio search state when in cover mode

Fixes #2742

> https://code.videolan.org/videolan/vlc-android/commit/148397549ca8cd172c1044a7c8f7ced4134659a7
---

 application/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/application/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt b/application/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
index 497198be4..ee842dd3f 100644
--- a/application/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
+++ b/application/vlc-android/src/org/videolan/vlc/gui/audio/AudioPlayer.kt
@@ -647,9 +647,9 @@ class AudioPlayer : Fragment(), PlaylistAdapter.IPlayer, TextWatcher, IAudioPlay
     }
 
     fun onSearchClick(v: View) {
+        if (isShowingCover()) onPlaylistSwitchClick(binding.playlistSwitch)
         manageSearchVisibilities(true)
         binding.playlistSearchText.editText?.requestFocus()
-        if (isShowingCover()) onPlaylistSwitchClick(binding.playlistSwitch)
         val imm = v.context.applicationContext.getSystemService<InputMethodManager>()!!
         imm.showSoftInput(binding.playlistSearchText.editText, InputMethodManager.SHOW_IMPLICIT)
         handler.postDelayed(hideSearchRunnable, SEARCH_TIMEOUT_MILLIS)



More information about the Android mailing list