Compartir a través de


PlayToManager.DefaultSourceSelection Propiedad

Definición

Habilita o deshabilita la selección de origen predeterminada para Reproducir en.

public:
 property bool DefaultSourceSelection { bool get(); void set(bool value); };
/// [get: Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, Windows.Foundation.UniversalApiContract)]
/// [set: Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, Windows.Foundation.UniversalApiContract)]
bool DefaultSourceSelection();

void DefaultSourceSelection(bool value);
/// [get: Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
/// [set: Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
bool DefaultSourceSelection();

void DefaultSourceSelection(bool value);
public bool DefaultSourceSelection { [Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, typeof(Windows.Foundation.UniversalApiContract))] get; [Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, typeof(Windows.Foundation.UniversalApiContract))] set; }
public bool DefaultSourceSelection { [Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")] get; [Windows.Foundation.Metadata.Deprecated("PlayToManager may be altered or unavailable for releases after Windows 10.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")] set; }
var boolean = playToManager.defaultSourceSelection;
playToManager.defaultSourceSelection = boolean;
Public Property DefaultSourceSelection As Boolean

Valor de propiedad

Boolean

bool

True para habilitar la selección de origen predeterminada; en caso contrario, false. El valor predeterminado es true.

Atributos

Comentarios

Una aplicación que contiene elementos multimedia tiene la opción Reproducir para habilitada de forma predeterminada. Si un usuario invoca el acceso Dispositivos mientras ejecuta la aplicación y selecciona un dispositivo de destino al que transmitir elementos multimedia, Reproducir para transmitirá el medio desde el primer elemento de audio, vídeo o imagen de la página actual. Puede deshabilitar este comportamiento predeterminado estableciendo la propiedad DefaultSourceSelection en false.

var ptm = Windows.Media.PlayTo.PlayToManager.getForCurrentView();
ptm.defaultSourceSelection = false;

Puede excluir elementos HTML individuales del comportamiento predeterminado Play To agregando el atributo -ms-playToDisabled en el marcado HTML.

<video src="http://www.example.com/videos/video.mp4" x-ms-playToDisabled/>

Se aplica a

Consulte también