LiveButton

fun LiveButton(modifier: Modifier = Modifier, contentPadding: PaddingValues = ButtonDefaults.TextButtonContentPadding, colors: IconButtonColors = IconButtonDefaults.iconButtonColors(), liveThreshold: Double = 10.0, live: @Composable RowScope.() -> Unit = { Icon( Icons.Rounded.Circle, modifier = Modifier.size(12.dp), tint = THEOplayerTheme.playerColors.liveButtonLive, contentDescription = null ) Text(text = " LIVE") }, dvr: @Composable RowScope.() -> Unit = { Icon( Icons.Rounded.Circle, modifier = Modifier.size(12.dp), tint = THEOplayerTheme.playerColors.liveButtonDvr, contentDescription = null ) Text(text = " LIVE") })

A button that shows whether the player is currently playing at the live point, and seeks to the live point when clicked.

Parameters

modifier

the Modifier to be applied to this button

contentPadding

the spacing values to apply internally between the container and the content

colors

ButtonColors that will be used to resolve the colors for this button in different states. See IconButtonDefaults.iconButtonColors

liveThreshold

the maximum distance (in seconds) from the live point that the player's current time can be for it to still be considered "at the live point"

live

button content when the player is playing at the live point, typically a red circle icon followed by the text "LIVE"

dvr

button content when the player is playing behind the live point, typically a gray circle icon followed by the text "LIVE"