Exemplo n.º 1
0
        /// <summary>
        /// Handle events from Game Monitor, on monitor thread
        /// We just dispatch them asynchronously over to ui thread
        /// </summary>
        private void _gameMonitor_GameChangeEvent(GameSession gameSession, GameMonitor.GameChangeType changeType)
        {
            object state = null;

            _uicontext.Post(new SendOrPostCallback(
                                (obj) => UiHandleGameChangeEvent(gameSession, changeType)), state);
        }
Exemplo n.º 2
0
 /// <summary>
 /// Handle Game Monitor events, now on ui thread
 /// </summary>
 private void UiHandleGameChangeEvent(GameSession gameSession, GameMonitor.GameChangeType changeType)
 {
     if (changeType != GameMonitor.GameChangeType.ChangeNone)
     {
         Logger.WriteDebug("Game {0} status change type {1} status {2}", gameSession.Description, changeType, gameSession.Status);
     }
     _viewModel.UpdateAccountStatus(gameSession.ServerName, gameSession.AccountName, gameSession.Status);
 }
Exemplo n.º 3
0
 /// <summary>
 /// Handle Game Monitor events, now on ui thread
 /// </summary>
 private void UiHandleGameChangeEvent(GameSession gameSession, GameMonitor.GameChangeType changeType)
 {
     _viewModel.UpdateAccountStatus(gameSession.ServerName, gameSession.AccountName, gameSession.Status);
 }