Пример #1
0
        public void Setup(MenuService service)
        {
            var settings = new MenuSettings {
                Start       = service.StartGame,
                ShowOptions = service.ShowOptions,
                Quit        = service.Quit
            };

            _components.Setup(settings);
        }
Пример #2
0
 public void Setup(MenuSettings settings)
 {
     _startButton.SetOnClickAction(settings.Start);
     _optionsButton.SetOnClickAction(settings.ShowOptions);
     _quitButton.SetOnClickAction(settings.Quit);
 }