public override void DidEnterBackground(UIApplication application)
 {
     PlatformBonsai.NotifyOfBackgroundChange(
         new PlatformModelBonsai {
         IsBackgroundAvailable = true, IsInBackground = true
     });
 }
 protected override void OnStart()
 {
     base.OnStart();
     PlatformBonsai.NotifyOfBackgroundChange(
         new PlatformModelBonsai {
         IsBackgroundAvailable = true
     });
 }
 public override void WillEnterForeground(UIApplication uiApplication)
 {
     base.WillEnterForeground(uiApplication);
     PlatformBonsai.NotifyOfBackgroundChange(
         new PlatformModelBonsai {
         IsBackgroundAvailable = true, IsInBackground = false
     });
 }
 public override void OnActivated(UIApplication application)
 {
     if (application.BackgroundRefreshStatus == UIBackgroundRefreshStatus.Available)
     {
         PlatformBonsai.NotifyOfBackgroundChange(
             new PlatformModelBonsai {
             IsBackgroundAvailable = true
         });
     }
     else
     {
         PlatformBonsai.NotifyOfBackgroundChange(
             new PlatformModelBonsai {
             IsBackgroundAvailable = false
         });
     }
 }