public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            RegisterComponents();

            var signIn = Google.Plus.SignIn.SharedInstance;

            signIn.ClientId = Build.GoogleOAuthClientId;
            signIn.Scopes   = new [] {
                "https://www.googleapis.com/auth/userinfo.profile",
                "https://www.googleapis.com/auth/userinfo.email",
            };

            Toggl.Ross.Theme.Style.Initialize();

            // Start app
            window = new TogglWindow(UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController();
            window.MakeKeyAndVisible();

            // Make sure critical services are running are running:
            ServiceContainer.Resolve <UpgradeManger> ().TryUpgrade();
            ServiceContainer.Resolve <IBugsnagClient> ();
            ServiceContainer.Resolve <BugsnagUserManager> ();

            #if DEBUG
            GAI.SharedInstance.DryRun = true;
            #endif
            ServiceContainer.Resolve <IGAITracker> ();

            return(true);
        }
示例#2
0
        public override bool FinishedLaunching (UIApplication application, NSDictionary launchOptions)
        {
            var versionString = UIDevice.CurrentDevice.SystemVersion;
            systemVersion = Convert.ToInt32 ( versionString.Split ( new [] {"."}, StringSplitOptions.None)[0]);

            // Attach bug tracker
            #if (!DEBUG)
            TestFairy.Begin (Build.TestFairyApiToken);
            #endif

            // Component initialisation.
            RegisterComponents ();

            // Setup Google sign in
            SetupGoogleServices ();

            Toggl.Ross.Theme.Style.Initialize ();

            // Start app
            window = new TogglWindow (UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController ();
            window.MakeKeyAndVisible ();

            // Make sure critical services are running are running:
            ServiceContainer.Resolve<UpgradeManger> ().TryUpgrade ();
            ServiceContainer.Resolve<ILoggerClient> ();
            ServiceContainer.Resolve<LoggerUserManager> ();
            ServiceContainer.Resolve<ITracker> ();
            ServiceContainer.Resolve<APNSManager> ();

            return true;
        }
示例#3
0
        public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
        {
            var versionString = UIDevice.CurrentDevice.SystemVersion;

            systemVersion = Convert.ToInt32(versionString.Split(new [] { "." }, StringSplitOptions.None)[0]);

            // Attach bug tracker
            #if (!DEBUG)
            RaygunClient.Attach(Build.RaygunApiKey);
            #endif

            // Component initialisation.
            RegisterComponents();

            // Setup Google sign in
            SetupGoogleServices();

            Toggl.Ross.Theme.Style.Initialize();

            // Start app
            window = new TogglWindow(UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController();
            window.MakeKeyAndVisible();

            // Make sure critical services are running are running:
            ServiceContainer.Resolve <UpgradeManger> ().TryUpgrade();
            ServiceContainer.Resolve <ILoggerClient> ();
            ServiceContainer.Resolve <LoggerUserManager> ();
            ServiceContainer.Resolve <ITracker> ();
            ServiceContainer.Resolve <APNSManager> ();

            return(true);
        }
示例#4
0
        public override bool FinishedLaunching (UIApplication app, NSDictionary options)
        {
            RegisterComponents ();

            var signIn = Google.Plus.SignIn.SharedInstance;
            signIn.ClientId = Build.GoogleOAuthClientId;
            signIn.Scopes = new [] {
                "https://www.googleapis.com/auth/userinfo.profile",
                "https://www.googleapis.com/auth/userinfo.email",
            };

            Toggl.Ross.Theme.Style.Initialize ();

            // Start app
            window = new TogglWindow (UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController ();
            window.MakeKeyAndVisible ();
            
            // Make sure critical services are running are running:
            ServiceContainer.Resolve<UpgradeManger> ().TryUpgrade ();
            ServiceContainer.Resolve<BugsnagClient> ();
            ServiceContainer.Resolve<BugsnagUserManager> ();

            #if DEBUG
            GAI.SharedInstance.DryRun = true;
            #endif
            ServiceContainer.Resolve<IGAITracker> ();

            return true;
        }
示例#5
0
        public override bool FinishedLaunching (UIApplication application, NSDictionary launchOptions)
        {
            var versionString = UIDevice.CurrentDevice.SystemVersion;
            systemVersion = Convert.ToInt32 ( versionString.Split ( new [] {"."}, StringSplitOptions.None)[0]);

            // Component initialisation.
            RegisterComponents ();

            // Setup Google sign in
            SetupGoogleServices ();

            Toggl.Ross.Theme.Style.Initialize ();

            // Start app
            window = new TogglWindow (UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController ();
            window.MakeKeyAndVisible ();

            // Make sure critical services are running are running:
            ServiceContainer.Resolve<UpgradeManger> ().TryUpgrade ();
            ServiceContainer.Resolve<ILoggerClient> ();
            ServiceContainer.Resolve<LoggerUserManager> ();
            ServiceContainer.Resolve<ITracker> ();
            ServiceContainer.Resolve<APNSManager> ();
            ServiceContainer.Resolve<QuickActions> ();

            if (launchOptions != null) {
                LaunchedShortcutItem = launchOptions [UIApplication.LaunchOptionsShortcutItemKey] as UIApplicationShortcutItem;
            }

            return LaunchedShortcutItem == null;
        }
示例#6
0
        public override bool FinishedLaunching (UIApplication application, NSDictionary launchOptions)
        {
            var versionString = UIDevice.CurrentDevice.SystemVersion;
            systemVersion = Convert.ToInt32 ( versionString.Split ( new [] {"."}, StringSplitOptions.None)[0]);

            // wait for component initialisation.
            RegisterComponentsAsync ();

            Toggl.Ross.Theme.Style.Initialize ();

            // Start app
            window = new TogglWindow (UIScreen.MainScreen.Bounds);
            window.RootViewController = new MainViewController ();
            window.MakeKeyAndVisible ();

            // Make sure critical services are running are running:
            ServiceContainer.Resolve<UpgradeManger> ().TryUpgrade ();
            ServiceContainer.Resolve<ILoggerClient> ();
            ServiceContainer.Resolve<LoggerUserManager> ();
            ServiceContainer.Resolve<ITracker> ();

            return true;
        }