Share via


MPMoviePlayerController.Notifications.ObserveThumbnailImageRequestDidFinish Method

Definition

Overloads

ObserveThumbnailImageRequestDidFinish(EventHandler<MPMoviePlayerThumbnailEventArgs>)

Strongly typed notification for the ThumbnailImageRequestDidFinishNotification constant.

public static Foundation.NSObject ObserveThumbnailImageRequestDidFinish(EventHandler<MediaPlayer.MPMoviePlayerThumbnailEventArgs> handler);
static member ObserveThumbnailImageRequestDidFinish : EventHandler<MediaPlayer.MPMoviePlayerThumbnailEventArgs> -> Foundation.NSObject

Parameters

handler
EventHandler<MPMoviePlayerThumbnailEventArgs>

The handler that responds to the notification when it occurs.

Returns

Token object that can be used to stop receiving notifications by either disposing it or passing it to RemoveObservers(IEnumerable<NSObject>).

Remarks

This method can be used to subscribe to ThumbnailImageRequestDidFinishNotification notifications.

// Listen to all notifications posted for any object
var token = MPMoviePlayerController.Notifications.ObserveThumbnailImageRequestDidFinish ((notification) => {
  Console.WriteLine ("Observed ThumbnailImageRequestDidFinishNotification!");
};

// Stop listening for notifications
token.Dispose ();

Applies to

ObserveThumbnailImageRequestDidFinish(NSObject, EventHandler<MPMoviePlayerThumbnailEventArgs>)

Strongly typed notification for the ThumbnailImageRequestDidFinishNotification constant.

public static Foundation.NSObject ObserveThumbnailImageRequestDidFinish(Foundation.NSObject objectToObserve, EventHandler<MediaPlayer.MPMoviePlayerThumbnailEventArgs> handler);
static member ObserveThumbnailImageRequestDidFinish : Foundation.NSObject * EventHandler<MediaPlayer.MPMoviePlayerThumbnailEventArgs> -> Foundation.NSObject

Parameters

objectToObserve
NSObject

The specific object to observe.

handler
EventHandler<MPMoviePlayerThumbnailEventArgs>

The handler that responds to the notification when it occurs.

Returns

Token object that can be used to stop receiving notifications by either disposing it or passing it to RemoveObservers(IEnumerable<NSObject>).

Remarks

This method can be used to subscribe to ThumbnailImageRequestDidFinishNotification notifications.

// Listen to all notifications posted for a single object
var token = MPMoviePlayerController.Notifications.ObserveThumbnailImageRequestDidFinish (objectToObserve, (notification) => {
  Console.WriteLine ($"Observed ThumbnailImageRequestDidFinishNotification for {nameof (objectToObserve)}!");
};

// Stop listening for notifications
token.Dispose ();

Applies to