public override IAppointment Copy()
        {
            IAppointment appointment = new CustomAppointment();

            appointment.CopyFrom(this);
            return(appointment);
        }
        public override void CopyFrom(IAppointment other)
        {
            CustomAppointment appointment = other as CustomAppointment;

            if (appointment != null)
            {
                this.SelectedReminder = appointment.SelectedReminder;
            }
            base.CopyFrom(other);
        }
Пример #3
0
        private void SetReminder()
        {
            var startList = this.Appointments
                            .Where(a => a.SelectedReminder != null).ToList();

            foreach (var app in startList)
            {
                if (app.Start <= DateTime.Now.Add(app.SelectedReminder.Value))
                {
                    this.SelectedAppointment = app;
                    if (this.SelectedAppointment != null && this.SelectedAppointment.SelectedReminder != null)
                    {
                        reminderWindow.Show();
                    }
                }
            }
        }
Пример #4
0
 public override IAppointment Copy()
 {
     IAppointment appointment = new CustomAppointment();
     appointment.CopyFrom(this);
     return appointment;
 }
Пример #5
0
        private void SetReminder()
        {
            var startList = this.Appointments
                .Where(a => a.SelectedReminder != null).ToList();
            foreach (var app in startList)
            {
				if (app.Start <= DateTime.Now.Add(app.SelectedReminder.Value))
                {
                    this.SelectedAppointment = app;
                    if (this.SelectedAppointment != null && this.SelectedAppointment.SelectedReminder != null)
                    {
                        reminderWindow.Show();
                    }
                }
            }
        }