Package-level declarations
This package contains the Compose components to integrate Media Routing in your application.
Functions
Link copied to clipboard
fun MediaRouteButton(modifier: Modifier = Modifier, routeSelector: MediaRouteSelector = MediaRouteSelector.EMPTY, colors: IconButtonColors = IconButtonDefaults.iconButtonColors(), mediaRouteChooserDialog: @Composable (onDismissRequest: () -> Unit) -> Unit = { onDismissRequest ->
MediaRouteChooserDialog(
routeSelector = routeSelector,
onDismissRequest = onDismissRequest,
)
}, mediaRouteDynamicChooserDialog: @Composable (onDismissRequest: () -> Unit) -> Unit = { onDismissRequest ->
// TODO Implement the correct dialog (see https://github.com/SRGSSR/androidx-mediarouter-compose/issues/18)
MediaRouteChooserDialog(
routeSelector = routeSelector,
onDismissRequest = onDismissRequest,
)
}, mediaRouteControllerDialog: @Composable (onDismissRequest: () -> Unit) -> Unit = { onDismissRequest ->
MediaRouteControllerDialog(
routeSelector = routeSelector,
onDismissRequest = onDismissRequest,
)
}, mediaRouteDynamicControllerDialog: @Composable (onDismissRequest: () -> Unit) -> Unit = { onDismissRequest ->
// TODO Implement the correct dialog (see https://github.com/SRGSSR/androidx-mediarouter-compose/issues/19)
MediaRouteControllerDialog(
routeSelector = routeSelector,
onDismissRequest = onDismissRequest,
)
})
The media route button allows the user to select routes and to control the currently selected route.
Link copied to clipboard
fun MediaRouteChooserDialog(routeSelector: MediaRouteSelector, modifier: Modifier = Modifier, onDismissRequest: () -> Unit)
This class implements the route chooser dialog for MediaRouter.
Link copied to clipboard
fun MediaRouteControllerDialog(routeSelector: MediaRouteSelector, modifier: Modifier = Modifier, volumeControlEnabled: Boolean = true, onDismissRequest: () -> Unit, customControlView: @Composable () -> Unit? = null)
This class implements the route controller dialog for MediaRouter.