Beispiel #1
0
        //
        // This method is invoked when the application has loaded and is ready to run. In this
        // method you should instantiate the window, load the UI into it and then make the window
        // visible.
        //
        // You have 17 seconds to return from this method, or iOS will terminate your application.
        //
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            Popup.Init();

            global::Xamarin.Forms.Forms.Init();
            Renderers.Init();
            DeviceOrientationImplementation.Init();

            //DependencyService.Register<ToastNotificatorImplementation>();
            //ToastNotificatorImplementation.Init();

            ImageCircleRenderer.Init();
            if (!Resolver.IsSet)
            {
                SetIoc();
            }
            LoadApplication(new MasTicket.App());

            MessagingCenter.Subscribe <Page, string>(this, "Share", (sender, arg) =>
            {
                Share(arg);
            });
            MessagingCenter.Subscribe <Page>(this, "LogOutFace", (sender) =>
            {
                LogOutFace();
            });

            //ShareImplementation.ExcludedUIActivityTypes = new List<NSString> { UIActivityType.PostToFacebook };

            Facebook.CoreKit.AppEvents.ActivateApp();

            return(base.FinishedLaunching(app, options));
        }
 // Constructor
 public MainPage()
 {
     InitializeComponent();
     Forms.Init();
     DeviceOrientationImplementation.Init();
     Content = DeviceOrientationDemo.App.GetMainPage().ConvertPageToUIElement(this);
 }
Beispiel #3
0
 protected override void OnCreate(Bundle bundle)
 {
     base.OnCreate(bundle);
     Xamarin.Forms.Forms.Init(this, bundle);
     DeviceOrientationImplementation.Init();
     SetPage(App.GetMainPage());
 }
Beispiel #4
0
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            global::Xamarin.Forms.Forms.Init();
            DeviceOrientationImplementation.Init();
            LoadApplication(new App());

            return(base.FinishedLaunching(app, options));
        }
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            Forms.Init();
            DeviceOrientationImplementation.Init();

            window = new UIWindow(UIScreen.MainScreen.Bounds);

            window.RootViewController = App.GetMainPage().CreateViewController();
            window.MakeKeyAndVisible();

            return(true);
        }
Beispiel #6
0
        protected override void OnCreate(Bundle bundle)
        {
            base.OnCreate(bundle);
            global::Xamarin.Forms.Forms.Init(this, bundle);
            Xamarin.FormsMaps.Init(this, bundle);
            UserDialogs.Init(this);
            DeviceOrientationImplementation.Init();

            Insights.Initialize("b4e84f033d5a063b8a2efcce69c58b8bd0ed5b6c", this);
            var app = new App();

            app.SetMapKey("AIzaSyDyAJ7CV-M44O0C_VcCWXiW6tBPX574l8c");
            LoadApplication(app);
        }
Beispiel #7
0
        protected override void OnCreate(Bundle bundle)
        {
            base.OnCreate(bundle);

            //ServicePointManager.ServerCertificateValidationCallback = MyRemoteCertificateValidationCallback;

            System.Net.ServicePointManager.ServerCertificateValidationCallback = delegate { return(true); };

            //ImageCircleRenderer.Init();
            global::Xamarin.Forms.Forms.Init(this, bundle);

            XamForms.Controls.Droid.Calendar.Init();

            //DependencyService.Register<ToastNotificatorImplementation>(); // Register your dependency
            //ToastNotificatorImplementation.Init(this);

            DeviceOrientationImplementation.Init();

            ImageCircleRenderer.Init();
            UserDialogs.Init(this);

            if (!Resolver.IsSet)
            {
                SetIoc();
            }

            LoadApplication(new MasTicket.App());

            MessagingCenter.Subscribe <Page, string>(this, "Share", (sender, arg) =>
            {
                Share(arg);
            });
            MessagingCenter.Subscribe <Page>(this, "LogOutFace", (sender) =>
            {
                LogOutFace();
            });

            Xamarin.Facebook.FacebookSdk.SdkInitialize(Xamarin.Forms.Forms.Context); 
 Xamarin.Facebook.AppEvents.AppEventsLogger.ActivateApp(Xamarin.Forms.Forms.Context);
        }
Beispiel #8
0
 public override void OnConfigurationChanged(Configuration newConfig)
 {
     base.OnConfigurationChanged(newConfig);
     DeviceOrientationImplementation.NotifyOrientationChange(newConfig);
 }
 protected override void OnOrientationChanged(OrientationChangedEventArgs e)
 {
     base.OnOrientationChanged(e);
     DeviceOrientationImplementation.NotifyOrientationChange(e);
 }
Beispiel #10
0
 public override void OnConfigurationChanged(global::Android.Content.Res.Configuration newConfig)
 {
     base.OnConfigurationChanged(newConfig);
     DeviceOrientationImplementation.NotifyOrientationChange(newConfig);
 }