Set episodes title length to max 3 lines, ellipsize at end

This commit is contained in:
Jannik 2022-03-30 20:27:10 +02:00
parent 1af82f8370
commit eaf1cf78e9
Signed by: Seil0
GPG Key ID: E8459F3723C52C24
2 changed files with 2 additions and 7 deletions

View File

@ -73,13 +73,6 @@ class EpisodeItemAdapter(
return episodes.size return episodes.size
} }
fun updateWatchedState(watched: Boolean, position: Int) {
// use getOrNull as there could be a index out of bound when running this in onResume()
// TODO
//episodes.getOrNull(position)?.watched = watched
}
inner class EpisodeViewHolder(val binding: ItemEpisodeBinding) : inner class EpisodeViewHolder(val binding: ItemEpisodeBinding) :
RecyclerView.ViewHolder(binding.root) { RecyclerView.ViewHolder(binding.root) {
init { init {

View File

@ -43,6 +43,8 @@
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_marginStart="7dp" android:layout_marginStart="7dp"
android:layout_weight="1" android:layout_weight="1"
android:ellipsize="end"
android:maxLines="3"
android:text="@string/component_episode_title" android:text="@string/component_episode_title"
android:textColor="?textPrimary" android:textColor="?textPrimary"
android:textSize="16sp" /> android:textSize="16sp" />