/// <summary> /// Override on create to instantiate the service container to be persistant. /// </summary> public override void OnCreate() { base.OnCreate(); //Registers services for core library ServiceRegistrar.Startup(); }
public App() { InitializeComponent(); ServiceRegistrar.Startup(); MainPage = new LoginView(); }
/// <summary> /// The entry point of the program, where the program control starts and ends. /// </summary> /// <param name='args'> /// The command-line arguments. /// </param> static void Main(string[] args) { //Setup our services for core library ServiceRegistrar.Startup(); // if you want to use a different Application Delegate class from "AppDelegate" you can specify it here. UIApplication.Main(args, null, "AppDelegate"); }
public override void OnCreate() { base.OnCreate(); var platform = new Microsoft.WindowsAzure.MobileServices.CurrentPlatform(); System.Diagnostics.Debug.WriteLine(platform); CurrentPlatform.Init(); ServiceRegistrar.Startup(); }
/// <summary> /// Class constructor /// </summary> public LoginActivity() { ServiceRegistrar.Startup(); loginViewModel = ServiceContainer.Resolve <LoginViewModel> (); //sets valid changed to show the login button. loginViewModel.IsValidChanged += (sender, e) => { if (login != null) { login.Enabled = loginViewModel.IsValid ? true : false; } }; }
// // 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) { // create a new window instance based on the screen size window = new UIWindow(UIScreen.MainScreen.Bounds); ServiceRegistrar.Startup(); navigationController = new UINavigationController(new ExpensesViewController()); // If you have defined a view, add it here: window.RootViewController = navigationController; // make the window visible window.MakeKeyAndVisible(); return(true); }
// // 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) { var platform = new Microsoft.WindowsAzure.MobileServices.CurrentPlatform(); System.Diagnostics.Debug.WriteLine(platform); // create a new window instance based on the screen size ServiceRegistrar.Startup(); UINavigationBar.Appearance.SetTitleTextAttributes(new UITextAttributes { TextColor = UIColor.White }); UINavigationBar.Appearance.TintColor = UIColor.White; UINavigationBar.Appearance.BarTintColor = UIColor.FromRGB(52, 152, 219); return(true); }
/// <summary> /// Initializes the singleton application object. This is the first line of authored code /// executed, and as such is the logical equivalent of main() or WinMain(). /// </summary> public App() { InitializeComponent(); //Create our RootFrame RootFrame = new Frame(); //Register services for core library ServiceRegistrar.Startup(); //WinRT specific services ServiceContainer.Register <LoginViewModel> (); ServiceContainer.Register <AssignmentViewModel> (); ServiceContainer.Register <ItemViewModel> (); ServiceContainer.Register <LaborViewModel> (); ServiceContainer.Register <PhotoViewModel>(); ServiceContainer.Register <ExpenseViewModel> (); ServiceContainer.Register <DocumentViewModel> (); ServiceContainer.Register <HistoryViewModel> (); ServiceContainer.Register(this); loginViewModel = ServiceContainer.Resolve <LoginViewModel> (); }
/// <summary> /// Constructor for the Application object. /// </summary> public App() { // Global handler for uncaught exceptions. UnhandledException += Application_UnhandledException; // Standard XAML initialization InitializeComponent(); // Phone-specific initialization InitializePhoneApplication(); // Language display initialization InitializeLanguage(); ServiceRegistrar.Startup(); // Show graphics profiling information while debugging. if (Debugger.IsAttached) { // Display the current frame rate counters. Application.Current.Host.Settings.EnableFrameRateCounter = true; // Show the areas of the app that are being redrawn in each frame. //Application.Current.Host.Settings.EnableRedrawRegions = true; // Enable non-production analysis visualization mode, // which shows areas of a page that are handed off GPU with a colored overlay. //Application.Current.Host.Settings.EnableCacheVisualization = true; // Prevent the screen from turning off while under the debugger by disabling // the application's idle detection. // Caution:- Use this under debug mode only. Application that disables user idle detection will continue to run // and consume battery power when the user is not using the phone. PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled; } }
public override void OnCreate() { base.OnCreate(); ServiceRegistrar.Startup(); }
public override void OnCreate() { base.OnCreate(); CurrentPlatform.Init(); ServiceRegistrar.Startup(); }