示例#1
0
 public AddEventPresenter(IAddEventView addEventView)
 {
     _addEventView        = addEventView;
     _eventDataValidation = new DataValidation();
     _taskService         = new TaskService(new TaskGoogleRepository(), null);
     _errorMessageView    = new ErrorMessageView();
     SubscribeToEventsSetup();
 }
示例#2
0
        private void OnAddEventButtonClickEventRaised(object sender, EventArgs e)
        {
            int                whatDay           = Convert.ToInt32((sender as Button).Text);
            DateTime           whatDate          = new DateTime(CurrentDate.Year, CurrentDate.Month, whatDay);
            IAddEventPresenter addEventPresenter = new AddEventPresenter(new AddEventView(whatDate));
            IAddEventView      addEventView      = addEventPresenter.GetAddEventView();

            addEventView.ShowWindow();
        }