Exemplo n.º 1
0
 public virtual void Insert(int index, DataGridViewCell dataGridViewCell)
 {
     base.List.Insert(index, dataGridViewCell);
     dataGridViewCell.SetOwningRow(dataGridViewRow);
     dataGridViewCell.SetColumnIndex(index);
     dataGridViewCell.SetDataGridView(dataGridViewRow.DataGridView);
     OnCollectionChanged(new CollectionChangeEventArgs(
                             CollectionChangeAction.Add, dataGridViewCell));
 }
Exemplo n.º 2
0
        public virtual int Add(DataGridViewCell dataGridViewCell)
        {
            int result = base.List.Add(dataGridViewCell);

            dataGridViewCell.SetOwningRow(dataGridViewRow);
            dataGridViewCell.SetColumnIndex(result);
            dataGridViewCell.SetDataGridView(dataGridViewRow.DataGridView);
            OnCollectionChanged(new CollectionChangeEventArgs(
                                    CollectionChangeAction.Add, dataGridViewCell));
            return(result);
        }
		public virtual void Insert (int index, DataGridViewCell dataGridViewCell)
		{
			base.List.Insert (index, dataGridViewCell);
			dataGridViewCell.SetOwningRow (dataGridViewRow);
			dataGridViewCell.SetColumnIndex (index);
			dataGridViewCell.SetDataGridView (dataGridViewRow.DataGridView);
			ReIndex ();
			OnCollectionChanged (new CollectionChangeEventArgs (
				CollectionChangeAction.Add, dataGridViewCell));
		}
		public virtual int Add (DataGridViewCell dataGridViewCell)
		{
			int result = base.List.Add (dataGridViewCell);
			dataGridViewCell.SetOwningRow (dataGridViewRow);
			dataGridViewCell.SetColumnIndex (result);
			dataGridViewCell.SetDataGridView (dataGridViewRow.DataGridView);
			OnCollectionChanged (new CollectionChangeEventArgs (
				CollectionChangeAction.Add, dataGridViewCell));
			return result;
		}