CastState

State holder for Chromecast controls, such as ChromecastButton and ChromecastDisplay.

The cast integration is only registered after the view is created, so this keeps track of the current Cast integration and moves its listeners when it changes.

Create an instance with rememberCastState.

Properties

Link copied to clipboard

Whether the player is casting.

Link copied to clipboard

The name of the connected Chromecast receiver, if any.

Link copied to clipboard
val castState: PlayerCastState

The current cast state of the player.

Functions

Link copied to clipboard

Starts casting to a Chromecast receiver.

Link copied to clipboard

Stops casting.