protected override void OnCreate(Bundle bundle) { base.OnCreate(bundle); Forms.SetFlags("FastRenderers_Experimental"); Forms.Init(this, bundle); FormsMaps.Init(this, bundle); ViewGesturesRenderer.Init(); CachedImageRenderer.Init(true); AndroidBug5497Workaround.AssistActivity(this); if (Build.VERSION.SdkInt >= BuildVersionCodes.Lollipop) { Window.DecorView.SystemUiVisibility = (StatusBarVisibility)(SystemUiFlags.LayoutStable | SystemUiFlags.LayoutFullscreen); } App.ScreenWidth = this.FromPixels(Resources.DisplayMetrics.WidthPixels); App.ScreenHeight = this.FromPixels(Resources.DisplayMetrics.HeightPixels); DependencyService.Register <IPhoneService, PhoneService>(); DependencyService.Register <IImageService, ImageService>(); LoadApplication(new App()); }
// // 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) { global::Xamarin.Forms.Forms.Init(); if (UIDevice.CurrentDevice.CheckSystemVersion(10, 0)) { // Ask the user for permission to get notifications on iOS 10.0+ UNUserNotificationCenter.Current.RequestAuthorization( UNAuthorizationOptions.Alert | UNAuthorizationOptions.Badge | UNAuthorizationOptions.Sound, (approved, error) => { }); UNUserNotificationCenter.Current.Delegate = new UserNotificationCenterDelegate(); } else if (UIDevice.CurrentDevice.CheckSystemVersion(8, 0)) { // Ask the user for permission to get notifications on iOS 8.0+ var settings = UIUserNotificationSettings.GetSettingsForTypes( UIUserNotificationType.Alert | UIUserNotificationType.Badge | UIUserNotificationType.Sound, new NSSet()); UIApplication.SharedApplication.RegisterUserNotificationSettings(settings); } // Set app theme UITabBar.Appearance.BarTintColor = UIColor.LightTextColor; UITabBar.Appearance.TintColor = UIColor.White; UIProgressView.Appearance.TintColor = UIColor.FromRGB(188, 75, 75); CachedImageRenderer.Init(); UINavigationBar.Appearance.BarTintColor = UIColor.FromRGB(255, 20, 153); UINavigationBar.Appearance.TintColor = UIColor.White; ViewGesturesRenderer.Init(); LoadApplication(new App()); return(base.FinishedLaunching(app, options)); }
// // 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) { global::Xamarin.Forms.Forms.Init(); ViewGesturesRenderer.Init(); LoadApplication(new SampleTitleBar.App()); return(base.FinishedLaunching(app, options)); }
protected override void OnCreate(Bundle bundle) { base.OnCreate(bundle); global::Xamarin.Forms.Forms.Init(this, bundle); ViewGesturesRenderer.Init(); LoadApplication(new SampleTitleBar.App()); }
public MainPage() { InitializeComponent(); SupportedOrientations = SupportedPageOrientation.PortraitOrLandscape; global::Xamarin.Forms.Forms.Init(); ViewGesturesRenderer.Init(); LoadApplication(new SampleTitleBar.App()); }
protected override void OnCreate(Bundle savedInstanceState) { TabLayoutResource = Resource.Layout.Tabbar; ToolbarResource = Resource.Layout.Toolbar; //Xamarin.Forms.Forms.SetFlags("FastRenderers_Experimental"); base.OnCreate(savedInstanceState); global::Xamarin.Forms.Forms.Init(this, savedInstanceState); ViewGesturesRenderer.Init(); LoadApplication(new App()); }
protected override void OnCreate(Bundle bundle) { base.OnCreate(bundle); Forms.Init(this, bundle); FormsMaps.Init(this, bundle); ViewGesturesRenderer.Init(); Forms.SetTitleBarVisibility(AndroidTitleBarVisibility.Never); LoadApplication(new App()); }
public override bool FinishedLaunching(UIApplication app, NSDictionary options) { MapServices.ProvideAPIKey(MapsApiKey); global::Xamarin.Forms.Forms.Init(); ViewGesturesRenderer.Init(); LoadApplication(new ScnDiscounts.App()); return(base.FinishedLaunching(app, options)); }
public MainPage() { InitializeComponent(); SupportedOrientations = SupportedPageOrientation.Portrait; global::Xamarin.Forms.Forms.Init(); ViewGesturesRenderer.Init(); string applicationId = "deede3e0-a6c7-4a26-84af-b6042b1ca302", authToken = "YVSma2K-u4Ctrd4IPdNvGw"; global::Xamarin.FormsMaps.Init(applicationId, authToken); LoadApplication(new ScnDiscounts.App()); }
public override bool FinishedLaunching(UIApplication app, NSDictionary options) { Forms.Init(); FormsMaps.Init(); ViewGesturesRenderer.Init(); CachedImageRenderer.Init(); MapServices.ProvideAPIKey(MapsApiKey); App.ScreenWidth = UIScreen.MainScreen.Bounds.Width; App.ScreenHeight = UIScreen.MainScreen.Bounds.Height; DependencyService.Register <IPhoneService, PhoneService>(); DependencyService.Register <IImageService, ImageService>(); LoadApplication(new App()); return(base.FinishedLaunching(app, options)); }
protected override void OnCreate(Bundle bundle) { TabLayoutResource = Resource.Layout.Tabbar; ToolbarResource = Resource.Layout.Toolbar; UserDialogs.Init(this); base.OnCreate(bundle); global::Xamarin.Forms.Forms.Init(this, bundle); IconEntryRenderer.Init(); LocalNotificationsImplementation.NotificationIconId = Resource.Drawable.ic_logo; CachedImageRenderer.Init(enableFastRenderer: true); ViewGesturesRenderer.Init(); //Microsoft.WindowsAzure.MobileServices.CurrentPlatform.Init(); Forms.Init(this, bundle); CurrentPlatform.Init(); LoadApplication(new App()); //Window.AddFlags(WindowManagerFlags.LayoutNoLimits); //Window.AddFlags(WindowManagerFlags.LayoutInScreen); //Window.DecorView.SetFitsSystemWindows(true); }
public MainPage() { InitializeComponent(); ViewGesturesRenderer.Init(); LoadApplication(new SimpleSideMenu.App()); }