title: Xamarin forms PushAsync opens a blank page
body: <p>I'm currently working on a project where I received push notification on the device, and when taping the notification it should open a specific page.</p>
  
  <p>I tried it on an Android 5.1, but when I tap the notification, it first opens the page and immediately after that it opens a blank page, whithout any navigation bar and I don't understand why...</p>
  
  <p>Here is my code:</p>
  
  <p>When I receive the the message on android I perform the following:</p>
  
  <pre><code>Intent intent = new Intent(this, typeof(MainActivity));
  intent.PutExtra("key", "message");
  PendingIntent pendingIntent = PendingIntent.GetActivity(this, 0, intent, PendingIntentFlags.OneShot);
  
  Notification notif = new Notification.Builder(this)
                          .SetSmallIcon(Resource.Drawable.icon)
                          .SetContentTitle("Alert")
                          .SetContentText("alert message")
                          .SetAutoCancel(true)
                          .SetDefaults(NotificationDefaults.Sound | NotificationDefaults.Vibrate)
                          .SetContentIntent(pendingIntent)
                          .SetPriority((int)NotificationPriority.High)
                          .Build();
  
  NotificationManager notificationManager = (NotificationManager)GetSystemService(Context.NotificationService);
  notificationManager.Notify(0, notif);
  </code></pre>
  
  <p>When taped it opens the MainActivity which does the following:</p>
  
  <pre><code>protected override void OnCreate(Bundle bundle)
  {
      TabLayoutResource = Resource.Layout.Tabbar;
      ToolbarResource = Resource.Layout.Toolbar;
  
      base.OnCreate(bundle);
      global::Xamarin.Forms.Forms.Init(this, bundle);
      if (app == null)
         app = new App();
      LoadApplication(app);
  
      // If the user tapped a notification
      if (Intent.Extras != null)
      {
          Data data = JsonConvert.DeserializeObject&lt;Data&gt;(Intent.Extras.GetString("key"));
          MessagingCenter.Send&lt;Data&gt;(data, "Show data");
      }
  }
  </code></pre>
  
  <p>Finally I have a DataPage (sets as the MainPage of the App, inside a NavigationPage) which does this:</p>
  
  <pre><code>public DataPage()
  {
      MessagingCenter.Subscribe&lt;Data&gt;(this, "Show data", (sender) =&gt;
      {
          await Navigation.PushAsync(new DataDetail(sender));
      });
  }
  </code></pre>
  
  <p>I don't really understand why this does not work properly...
  Especially since if I do </p>
  
  <pre><code>await Xamarin.Forms.Application.Current.MainPage.Navigation.PushModalAsync(new NavigationPage(new DataPage(data)));
  </code></pre>
  
  <p>And create a second constructor in the DataPage:</p>
  
  <pre><code>DataPage(Data data)
  {
      await Navigation.PushAsync(new DataDetail(data));
  }
  </code></pre>
  
  <p>It works fine. (But I don't like this, it looks very... not nice)</p>