protected override void OnElementChanged(ElementChangedEventArgs <FormsMapView> e)
        {
            base.OnElementChanged(e);

            if (e.OldElement != null)
            {
                // Unsubscribe from event handlers and cleanup any resources
                ActivityLifecycleNotifier.Unregister(this);
            }

            if (e.NewElement != null)
            {
                if (Control == null)
                {
                    // Instantiate the native control and assign it to the Control property with
                    // the SetNativeControl method
                    var mapView = new MapView(Context);
                    SetNativeControl(mapView);
                    //Control.OnCreate(ActivityLifecycleNotifier.LastActivityCreateBundle);
                    //Control.OnResume();
                }

                Control.GetMapAsync(this);
                // Configure the control and subscribe to event handlers
                ActivityLifecycleNotifier.Register(this);
                Control.LayoutParameters = new LayoutParams(LayoutParams.MatchParent, LayoutParams.MatchParent);
            }
        }
        protected override void OnCreate(Bundle savedInstanceState)
        {
            TabLayoutResource = Resource.Layout.Tabbar;
            ToolbarResource   = Resource.Layout.Toolbar;

            base.OnCreate(savedInstanceState);

            Xamarin.Essentials.Platform.Init(this, savedInstanceState);
            global::Xamarin.Forms.Forms.Init(this, savedInstanceState);
            LoadApplication(new App());

            ActivityLifecycleNotifier.OnCreate(savedInstanceState);
        }
 public override void OnLowMemory()
 {
     base.OnLowMemory();
     ActivityLifecycleNotifier.OnLowMemory();
 }
 protected override void OnSaveInstanceState(Bundle outState)
 {
     base.OnSaveInstanceState(outState);
     ActivityLifecycleNotifier.OnSaveInstanceState(outState);
 }
 protected override void OnDestroy()
 {
     base.OnDestroy();
     ActivityLifecycleNotifier.OnDestroy();
 }
 protected override void OnStop()
 {
     base.OnStop();
     ActivityLifecycleNotifier.OnStop();
 }