mirror of
https://github.com/nextcloud/android.git
synced 2024-11-26 07:05:49 +03:00
hide stub view when player ready
Signed-off-by: parneet-guraya <gurayaparneet@gmail.com>
This commit is contained in:
parent
fbb51b0935
commit
f02a997ed0
1 changed files with 3 additions and 2 deletions
|
@ -259,7 +259,7 @@ class PreviewMediaActivity :
|
|||
binding.emptyView.emptyListView.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
private fun setVideoErrorMessage(headline: String, @StringRes message: Int) {
|
||||
private fun setErrorMessage(headline: String, @StringRes message: Int) {
|
||||
binding.emptyView.run {
|
||||
emptyListViewHeadline.text = headline
|
||||
emptyListViewText.setText(message)
|
||||
|
@ -401,6 +401,7 @@ class PreviewMediaActivity :
|
|||
override fun onPlaybackStateChanged(playbackState: Int) {
|
||||
if (playbackState == Player.STATE_READY) {
|
||||
hideProgressLayout()
|
||||
binding.emptyView.emptyListView.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -720,7 +721,7 @@ class PreviewMediaActivity :
|
|||
}
|
||||
} else {
|
||||
emptyListView?.visibility = View.VISIBLE
|
||||
setVideoErrorMessage(
|
||||
setErrorMessage(
|
||||
weakReference.getString(R.string.stream_not_possible_headline),
|
||||
R.string.stream_not_possible_message
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue