Partager via


PdfView.PageChangedNotification Propriété

Définition

Constante de notification pour PageChanged

[Foundation.Advice("Use PdfView.Notifications.ObservePageChanged helper method instead.")]
[Foundation.Field("PDFViewPageChangedNotification", "PDFKit")]
public static Foundation.NSString PageChangedNotification { get; }
[Foundation.Advice("Use PdfView.Notifications.ObservePageChanged helper method instead.")]
[Foundation.Field("PDFViewPageChangedNotification", "Quartz")]
public static Foundation.NSString PageChangedNotification { get; }
member this.PageChangedNotification : Foundation.NSString

Valeur de propriété

La constante NSString doit être utilisée comme jeton pour NSNotificationCenter.

Attributs

Remarques

Cette constante peut être utilisée avec pour NSNotificationCenter inscrire un écouteur pour cette notification. Les développeurs peuvent également utiliser la notification ObservePageChanged fortement typée à la place. Il s’agit d’un NSString au lieu d’une chaîne, car ces valeurs peuvent être utilisées comme jetons dans certaines bibliothèques natives au lieu d’être utilisées uniquement pour leur contenu de chaîne réel. Le paramètre « notification » du rappel contient des informations supplémentaires spécifiques au type de notification.

// Lambda style
NSNotificationCenter.DefaultCenter.AddObserver (
        PdfView.PageChangedNotification, (notification) => {Console.WriteLine ("Received the notification PdfView", notification); }


// Method style
void Callback (NSNotification notification)
{
    Console.WriteLine ("Received a notification PdfView", notification);
}

void Setup ()
{
    NSNotificationCenter.DefaultCenter.AddObserver (PdfView.PageChangedNotification, Callback);
}

S’applique à