public WeekText[] ToMonthTextArray() { WeekText[] ms = new WeekText[this.Count]; for (int i = 0; i < this.Count; ++i) { ms[i] = this[i]; } return(ms); }
public override object ConvertTo(ITypeDescriptorContext context, System.Globalization.CultureInfo culture, object value, Type destinationType) { if (destinationType == typeof(InstanceDescriptor)) { WeekText w = (WeekText)value; ConstructorInfo cInfo = typeof(WeekText).GetConstructor(new Type[] { typeof(DayOfWeek), typeof(string), typeof(Color) }); return(new InstanceDescriptor(cInfo, new object[] { w.Day, w.Text, w.BackColor }, true)); } return(base.ConvertTo(context, culture, value, destinationType)); }
public bool Contains(DayOfWeek day) { WeekText w = new WeekText(day, string.Empty, Color.Empty); return(this.Contains(w)); }
public bool Contains(WeekText value) { // If value is not of type Int16, this will return false. return(List.Contains(value)); }
public void Remove(WeekText value) { List.Remove(value); }
public void Insert(int index, WeekText value) { List.Insert(index, value); }
public int IndexOf(DayOfWeek day) { WeekText w = new WeekText(day, string.Empty, Color.Empty); return(this.IndexOf(w)); }
public int IndexOf(WeekText value) { return(List.IndexOf(value)); }
public int Add(WeekText value) { return(List.Add(value)); }