public override object Clone() { MyDgvMcComboBoxCell cell = base.Clone() as MyDgvMcComboBoxCell; cell.ColumnNames = ColumnNames; cell.ColumnWidths = ColumnWidths; cell.DropDownStyle = this.DropDownStyle; cell.ItemStrings = this.ItemStrings; cell.LimitToList = this.LimitToList; cell.NullToDBNull = this.NullToDBNull; return(cell); }
public void ScaleColumn(SizeF factor) { this.ComboBoxCellTemplateA.ScaleColumn(factor); if (base.DataGridView != null) { DataGridViewRowCollection rows = base.DataGridView.Rows; int count = rows.Count; for (int i = 0; i < count; i++) { MyDgvMcComboBoxCell cell = rows.SharedRow(i).Cells[base.Index] as MyDgvMcComboBoxCell; if (cell != null) { cell.ScaleColumn(factor); } } } }