Condividi tramite


PdfView.VisiblePagesChangedNotification Proprietà

Definizione

Costante di notifica per VisiblePagesChanged

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

Valore della proprietà

La costante NSString deve essere usata come token per NSNotificationCenter.

Attributi

Commenti

Questa costante può essere usata con per NSNotificationCenter registrare un listener per questa notifica, anche gli sviluppatori possono usare la notifica ObserveVisiblePagesChanged fortemente tipizzata. Si tratta di un NSString anziché di una stringa, perché questi valori possono essere usati come token in alcune librerie native anziché essere usati esclusivamente per il contenuto stringa effettivo. Il parametro 'notification' del callback contiene informazioni aggiuntive specifiche per il tipo di notifica.

// Lambda style
NSNotificationCenter.DefaultCenter.AddObserver (
        PdfView.VisiblePagesChangedNotification, (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.VisiblePagesChangedNotification, Callback);
}

Si applica a