Exemplo n.º 1
0
Arquivo: Push.cs Projeto: ManjuBP/.net
 static Push()
 {
     _pushDelegate.OnPushNotificationReceivedAction = notification =>
     {
         var pushEventArgs = new PushNotificationReceivedEventArgs
         {
             Title      = notification.Title,
             Message    = notification.Message,
             CustomData = notification.CustomData?.ToDictionary(i => i.Key.ToString(), i => i.Value.ToString())
         };
         PushNotificationReceived?.Invoke(null, pushEventArgs);
     };
     MSPush.SetDelegate(_pushDelegate);
 }
Exemplo n.º 2
0
 static Push()
 {
     _pushDelegate.OnPushNotificationReceivedAction = notification =>
     {
         var pushEventArgs = new PushNotificationReceivedEventArgs
         {
             Title      = notification.Title,
             Message    = notification.Message,
             CustomData = NSDictionaryToDotNet(notification.CustomData)
         };
         PushNotificationReceived?.Invoke(null, pushEventArgs);
     };
     MSPush.SetDelegate(_pushDelegate);
 }