Bagikan melalui


MediaPlayer.PlaybackMediaMarkerReached Kejadian

Definisi

Terjadi ketika penanda media telah tercapai selama pemutaran.

Catatan

MediaPlayer.PlaybackMediaMarkerReached dapat diubah atau tidak tersedia setelah Windows 10, versi 1607. Sebagai gantinya, gunakan MediaPlaybackItem.TimedMetadataTracks untuk mengelola tanda data atau teks. Untuk informasi selengkapnya, lihat Pemutaran media dengan MediaSource.

// Register
event_token PlaybackMediaMarkerReached(TypedEventHandler<MediaPlayer, PlaybackMediaMarkerReachedEventArgs const&> const& handler) const;

// Revoke with event_token
void PlaybackMediaMarkerReached(event_token const* cookie) const;

// Revoke with event_revoker
MediaPlayer::PlaybackMediaMarkerReached_revoker PlaybackMediaMarkerReached(auto_revoke_t, TypedEventHandler<MediaPlayer, PlaybackMediaMarkerReachedEventArgs const&> const& handler) const;
/// [add: Windows.Foundation.Metadata.Deprecated("Use media tracks on MediaPlaybackItem instead of PlaybackMediaMarkers.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.Foundation.UniversalApiContract")]
/// [remove: Windows.Foundation.Metadata.Deprecated("Use media tracks on MediaPlaybackItem instead of PlaybackMediaMarkers.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.Foundation.UniversalApiContract")]
// Register
event_token PlaybackMediaMarkerReached(TypedEventHandler<MediaPlayer, PlaybackMediaMarkerReachedEventArgs const&> const& handler) const;

// Revoke with event_token
void PlaybackMediaMarkerReached(event_token const* cookie) const;

// Revoke with event_revoker
MediaPlayer::PlaybackMediaMarkerReached_revoker PlaybackMediaMarkerReached(auto_revoke_t, TypedEventHandler<MediaPlayer, PlaybackMediaMarkerReachedEventArgs const&> const& handler) const;
public event TypedEventHandler<MediaPlayer,PlaybackMediaMarkerReachedEventArgs> PlaybackMediaMarkerReached;
[add: Windows.Foundation.Metadata.Deprecated("Use media tracks on MediaPlaybackItem instead of PlaybackMediaMarkers.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.Foundation.UniversalApiContract")]
[remove: Windows.Foundation.Metadata.Deprecated("Use media tracks on MediaPlaybackItem instead of PlaybackMediaMarkers.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 131072, "Windows.Foundation.UniversalApiContract")]
public event TypedEventHandler<MediaPlayer,PlaybackMediaMarkerReachedEventArgs> PlaybackMediaMarkerReached;
function onPlaybackMediaMarkerReached(eventArgs) { /* Your code */ }
mediaPlayer.addEventListener("playbackmediamarkerreached", onPlaybackMediaMarkerReached);
mediaPlayer.removeEventListener("playbackmediamarkerreached", onPlaybackMediaMarkerReached);
- or -
mediaPlayer.onplaybackmediamarkerreached = onPlaybackMediaMarkerReached;
Public Custom Event PlaybackMediaMarkerReached As TypedEventHandler(Of MediaPlayer, PlaybackMediaMarkerReachedEventArgs) 

Jenis Acara

Atribut

Berlaku untuk