示例#1
0
        public async void OnActivated(IActivatedEventArgs args)
        {
            CreateRootFrame();
            await RestoreStatus(args.PreviousExecutionState);

            PincodeManager.TriggerBackgroundedPinTimer();
        }
        public async void OnActivated(IActivatedEventArgs args)
        {
            CreateRootFrame();
            await RestoreStatus(args.PreviousExecutionState);

            if (args.PreviousExecutionState == ApplicationExecutionState.Terminated)
            {
                ContinuationManager.MarkAsStale();
            }

            PincodeManager.TriggerBackgroundedPinTimer();
            if (args is IContinuationActivatedEventArgs)
            {
                var continueEvents = args as IContinuationActivatedEventArgs;
                ContinuationManager.MarkAsStale();
                try
                {
                    PlatformAdapter.SendToCustomLogger("SFApplicationHelper.OnActivated - Calling ContinuationManager.Continue", LoggingLevel.Verbose);
                    ContinuationManager.Continue(continueEvents);
                }
                catch (InvalidOperationException e)
                {
                    PlatformAdapter.SendToCustomLogger("SFApplicationHelper.OnActivated - Exception when calling ContinuationManager.Continue", LoggingLevel.Critical);
                    PlatformAdapter.SendToCustomLogger(e, LoggingLevel.Critical);
                    Debug.WriteLine("Exception while continuing, " + e.StackTrace);
                }
            }
            Window.Current.Activate();
        }
示例#3
0
        public async void OnSuspending(SuspendingEventArgs e)
        {
            SuspendingDeferral deferral = e.SuspendingOperation.GetDeferral();

            PincodeManager.SavePinTimer();
            await SuspensionManager.SaveAsync();

            deferral.Complete();
        }
        private async void accountsList_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            await AccountManager.SwitchToAccount(AccountsList.SelectedItem as Account);

            SDKManager.ResetClientManager();
            if (SDKManager.GlobalClientManager.PeekRestClient() != null)
            {
                Frame.Navigate(SDKManager.RootApplicationPage);
                Account account = AccountManager.GetAccount();
                PincodeManager.LaunchPincodeScreen();
            }
        }
示例#5
0
 private void CoreVisibilityChanged(CoreWindow sender, VisibilityChangedEventArgs args)
 {
     if (args.Visible)
     {
         PincodeManager.TriggerBackgroundedPinTimer();
         TokenRefresher.Start();
     }
     else
     {
         PincodeManager.SavePinTimer();
         TokenRefresher.Stop();
     }
 }
        private SalesforceAnalyticsManager(Account account, string communityId)
        {
            var deviceAppAttributes = BuildDeviceAppAttributes();

            analyticsManager = new AnalyticsManager(account.GetCommunityLevelFileNameSuffix(), deviceAppAttributes,
                                                    PincodeManager.RetrievePinCodeHash());
            eventStoreManager = (EventStoreManager)analyticsManager.GetEventStoreManager();
            remotes           = new Dictionary <ITransform, IAnalyticsPublisher>();
            var transformer = new AiltnTransform();
            var publisher   = new AiltnPublisher();

            remotes.Add(transformer, publisher);
        }
示例#7
0
 private void coreWindow_PointerMoved(CoreWindow sender, PointerEventArgs args)
 {
     PincodeManager.StartIdleTimer();
 }