public void InitGameControllerList(object param) { GameControllers.Clear(); foreach (var device in _deviceService.GetDevices()) { GameControllers.Add(device); } SelectedDevice = GameControllers.Any(g => g.DeviceGuid == Configuration.DeviceGuid) ? GameControllers.FirstOrDefault(g => g.DeviceGuid == Configuration.DeviceGuid) : GameControllers.FirstOrDefault(); IsControllerButtonEnabled = GameControllers.Any(); StartLightService(); }
public IGamesTracker StartTracking(string fullPath) { if (GameControllers.ContainsKey(fullPath)) { PublishUserWarningMessage(fullPath); return(this); } IGameController gameController = SetupGameController(fullPath); GameControllers.Add(fullPath, gameController); _newHandsTracker.TrackFolder(new FileInfo(fullPath).DirectoryName); _newHandsTracker.ProcessHandHistoriesInFile(fullPath); return(this); }