Ejemplo n.º 1
0
        private void HandleQueryUserStatusCompleted(object sender, AsyncCompletedEventArgs <UserStateInfoResponse> e)
        {
            if (e.IsErrored())
            {
                return;
            }

            if (e.Result.State == TimeWarpState.None)
            {
                _userStateService.StartWorkAsync();
            }
        }
Ejemplo n.º 2
0
 public StartStopViewModel(IUserStateService userStateService)
 {
     WorkCommand = new DelegateCommand(_ =>
                                       userStateService.StartWorkAsync());
     RestCommand = new DelegateCommand(_ => userStateService.StopWorkAsync());
 }