PdfView.Notifications.ObserveDisplayBoxChanged Metodo
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Overload
ObserveDisplayBoxChanged(EventHandler<NSNotificationEventArgs>) |
Notifica fortemente tipizzata per la DisplayBoxChangedNotification costante. |
ObserveDisplayBoxChanged(NSObject, EventHandler<NSNotificationEventArgs>) |
Notifica fortemente tipizzata per la DisplayBoxChangedNotification costante. |
ObserveDisplayBoxChanged(EventHandler<NSNotificationEventArgs>)
Notifica fortemente tipizzata per la DisplayBoxChangedNotification costante.
public static Foundation.NSObject ObserveDisplayBoxChanged(EventHandler<Foundation.NSNotificationEventArgs> handler);
static member ObserveDisplayBoxChanged : EventHandler<Foundation.NSNotificationEventArgs> -> Foundation.NSObject
Parametri
- handler
- EventHandler<NSNotificationEventArgs>
Metodo da richiamare quando viene pubblicata la notifica.
Restituisce
Oggetto token che può essere usato per arrestare la ricezione delle notifiche eliminandolo o passandolo a RemoveObservers(IEnumerable<NSObject>)
Commenti
Questo metodo può essere usato per sottoscrivere DisplayBoxChangedNotification le notifiche.
// Listen to all notifications posted for any object
var token = PdfView.Notifications.ObserveDisplayBoxChanged ((notification) => {
Console.WriteLine ("Observed DisplayBoxChangedNotification!");
};
// Listen to all notifications posted for a single object
var token = PdfView.Notifications.ObserveDisplayBoxChanged (objectToObserve, (notification) => {
Console.WriteLine ($"Observed DisplayBoxChangedNotification for {nameof (objectToObserve)}!");
};
// Stop listening for notifications
token.Dispose ();
Si applica a
ObserveDisplayBoxChanged(NSObject, EventHandler<NSNotificationEventArgs>)
Notifica fortemente tipizzata per la DisplayBoxChangedNotification costante.
public static Foundation.NSObject ObserveDisplayBoxChanged(Foundation.NSObject objectToObserve, EventHandler<Foundation.NSNotificationEventArgs> handler);
static member ObserveDisplayBoxChanged : Foundation.NSObject * EventHandler<Foundation.NSNotificationEventArgs> -> Foundation.NSObject
Parametri
- objectToObserve
- NSObject
Oggetto da osservare.
- handler
- EventHandler<NSNotificationEventArgs>
Metodo da richiamare quando viene pubblicata la notifica.
Restituisce
Oggetto token che può essere usato per arrestare la ricezione delle notifiche eliminandolo o passandolo a RemoveObservers(IEnumerable<NSObject>)
Commenti
Questo metodo può essere usato per sottoscrivere DisplayBoxChangedNotification le notifiche.
// Listen to all notifications posted for any object
var token = PdfView.Notifications.ObserveDisplayBoxChanged ((notification) => {
Console.WriteLine ("Observed DisplayBoxChangedNotification!");
};
// Listen to all notifications posted for a single object
var token = PdfView.Notifications.ObserveDisplayBoxChanged (objectToObserve, (notification) => {
Console.WriteLine ($"Observed DisplayBoxChangedNotification for {nameof (objectToObserve)}!");
};
// Stop listening for notifications
token.Dispose ();