SourceChangeRequestedEventArgs Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides information about the SourceChangeRequested event.
public ref class SourceChangeRequestedEventArgs sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
class SourceChangeRequestedEventArgs final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
public sealed class SourceChangeRequestedEventArgs
Public NotInheritable Class SourceChangeRequestedEventArgs
- Inheritance
- Attributes
Windows requirements
Device family |
Windows 10 (introduced in 10.0.10240.0)
|
API contract |
Windows.Foundation.UniversalApiContract (introduced in v1.0)
|
Remarks
For an example of creating a software Play To receiver, see Media casting.
async void receiver_SourceChangeRequested(
Windows.Media.PlayTo.PlayToReceiver sender,
Windows.Media.PlayTo.SourceChangeRequestedEventArgs args)
{
if (args.Stream != null)
await dispatcher.RunAsync(
Windows.UI.Core.CoreDispatcherPriority.Normal, () =>
{
var stream = args.Stream as Windows.Storage.Streams.IRandomAccessStream;
VideoPlayer.SetSource(stream, args.Stream.ContentType);
});
}
Async Sub receiver_SourceChangeRequested(
sender As Windows.Media.PlayTo.PlayToReceiver,
args As Windows.Media.PlayTo.SourceChangeRequestedEventArgs)
If args.Stream IsNot Nothing Then
Await Dispatcher.RunAsync(
Windows.UI.Core.CoreDispatcherPriority.Normal,
Sub()
Dim stream = TryCast(args.Stream, Windows.Storage.Streams.IRandomAccessStream)
VideoPlayer.SetSource(stream, args.Stream.ContentType)
End Sub)
End If
End Sub
Properties
Album |
Gets the name of the album that contains the song in the audio stream. |
Author |
Gets the author of the content in the media stream. |
Date |
Gets the date that the content in the media stream was published. |
Description |
Gets the description of the content in the media stream. |
Genre |
Gets the names of the genres that the content in the media stream belongs to. |
Properties |
Gets custom property names and values for the content in the media stream. |
Rating |
Gets the rating for the content in the media stream. |
Stream |
Gets the media stream for the Play To receiver. |
Thumbnail |
Gets the thumbnail image for the content in the media stream. |
Title |
Gets the title of the content in the media stream. |