public virtual object this[GanttViewDataItem item] { get { if (item.Cache[this.Column] == null) { PropertyInfo property = item.GetType().GetProperty(this.Column.FieldName); if ((object)property != null) { object obj = property.GetValue((object)item, (object[])null); this.SetUnboundValue(item, obj); } } return(item.Cache[this.Column]); } set { this.SetUnboundValue(item, value); } }
private void SetUnboundValue(GanttViewDataItem item, object value) { if (item == null) { return; } if (this.GanttViewElement != null) { this.GanttViewElement.Items.OnCollectionItemChanging(item); } item.Cache[this.column] = value; PropertyInfo property = item.GetType().GetProperty(this.column.FieldName); if ((object)property != null) { property.SetValue((object)item, value, (object[])null); } if (this.GanttViewElement == null) { return; } this.GanttViewElement.Items.OnCollectionItemChanged(item); }