mirror of
https://github.com/libre-tube/LibreTube.git
synced 2024-12-14 06:10:31 +05:30
Merge pull request #6218 from Bnyro/master
feat: button to play recent videos from a channel
This commit is contained in:
commit
4f22fb0089
@ -181,6 +181,13 @@ class ChannelFragment : DynamicLayoutManagerFragment() {
|
|||||||
}.show(childFragmentManager)
|
}.show(childFragmentManager)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
binding.playAll.setOnClickListener {
|
||||||
|
val firstVideoId =
|
||||||
|
response.relatedStreams.firstOrNull()?.url?.toID() ?: return@setOnClickListener
|
||||||
|
|
||||||
|
NavigationHelper.navigateVideo(requireContext(), firstVideoId, channelId = channelId)
|
||||||
|
}
|
||||||
|
|
||||||
nextPages[0] = response.nextpage
|
nextPages[0] = response.nextpage
|
||||||
isLoading = false
|
isLoading = false
|
||||||
binding.channelRefresh.isRefreshing = false
|
binding.channelRefresh.isRefreshing = false
|
||||||
|
@ -131,6 +131,15 @@
|
|||||||
app:icon="@drawable/ic_add"
|
app:icon="@drawable/ic_add"
|
||||||
tools:targetApi="m" />
|
tools:targetApi="m" />
|
||||||
|
|
||||||
|
<com.google.android.material.button.MaterialButton
|
||||||
|
android:id="@+id/play_all"
|
||||||
|
style="@style/PlayerActionsButton"
|
||||||
|
android:text="@string/play_latest_videos"
|
||||||
|
android:textSize="12sp"
|
||||||
|
android:tooltipText="@string/play_latest_videos"
|
||||||
|
app:icon="@drawable/ic_playlist"
|
||||||
|
tools:targetApi="m" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</HorizontalScrollView>
|
</HorizontalScrollView>
|
||||||
|
Loading…
Reference in New Issue
Block a user