Exemple #1
0
 public WeekText[] ToMonthTextArray()
 {
     WeekText[] ms = new WeekText[this.Count];
     for (int i = 0; i < this.Count; ++i)
     {
         ms[i] = this[i];
     }
     return(ms);
 }
Exemple #2
0
 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));
 }
Exemple #3
0
        public bool Contains(DayOfWeek day)
        {
            WeekText w = new WeekText(day, string.Empty, Color.Empty);

            return(this.Contains(w));
        }
Exemple #4
0
 public bool Contains(WeekText value)
 {
     // If value is not of type Int16, this will return false.
     return(List.Contains(value));
 }
Exemple #5
0
 public void Remove(WeekText value)
 {
     List.Remove(value);
 }
Exemple #6
0
 public void Insert(int index, WeekText value)
 {
     List.Insert(index, value);
 }
Exemple #7
0
        public int IndexOf(DayOfWeek day)
        {
            WeekText w = new WeekText(day, string.Empty, Color.Empty);

            return(this.IndexOf(w));
        }
Exemple #8
0
 public int IndexOf(WeekText value)
 {
     return(List.IndexOf(value));
 }
Exemple #9
0
 public int Add(WeekText value)
 {
     return(List.Add(value));
 }