private void InitTimer(ITimerServiceManager timerServiceManager) { if (timerServiceManager != null) { _timerService = timerServiceManager.GetTimer(GameSettings.GameType.Timer, Timer); } _timerService.InitTimer(this); }
public GameViewModel(ISettingsService settingsService, IDialogCoordinator dialogCoordinator, IChessboard chessboard, ITimerServiceManager timerServiceManager) : base(settingsService, dialogCoordinator, chessboard) { LoadGameSettings(); InitTimer(timerServiceManager); PlayGameCommand = new RelayCommand(PlayGame); RestartGameCommand = new RelayCommand(RestetGame); DisplayInfoCommand = new RelayCommand(DisplayInfo); }