Skip to content

Latest commit

 

History

History
40 lines (24 loc) · 2.17 KB

mediaplayerelement_aretransportcontrolsenabled.md

File metadata and controls

40 lines (24 loc) · 2.17 KB
-api-id -api-type
P:Microsoft.UI.Xaml.Controls.MediaPlayerElement.AreTransportControlsEnabled
winrt property

Microsoft.UI.Xaml.Controls.MediaPlayerElement.AreTransportControlsEnabled

-description

Gets or sets a value that determines whether the standard transport controls are enabled.

-xaml-syntax

<MediaPlayerElement AreTransportControlsEnabled="bool"/>

-property-value

true if the standard transport controls are enabled; otherwise, false. The default is false.

-remarks

The transport controls are exposed as a MediaTransportControls object that you can access through the MediaPlayerElement.TransportControls property. See MediaTransportControls for more info.

If AreTransportControlsEnabled is true, the standard transport controls are enabled and displayed on the MediaPlayerElement. If AreTransportControlsEnabled is false, the standard transport controls are not enabled and are not displayed.

The transport controls hide themselves after a short period of no user interaction with the MediaPlayerElement. They reappear when the user interacts with the MediaPlayerElement.

If the Width of MediaPlayerElement is not sufficient to display all of the transport controls, a subset of the controls are displayed.

Note

If you disable the MediaPlaybackCommandManager by setting IsEnabled to false, it will break the link between the MediaPlayer the TransportControls provided by the MediaPlayerElement, so the built-in transport controls will no longer automatically control the playback of the player. Instead, you must implement your own controls to control the MediaPlayer.

-examples