Class DataGridTimePickerCellRenderer
A class for cell renderer that displays TimeSpan in a DataGridCell.
Inheritance
DataGridTimePickerCellRenderer
Inherited Members
Namespace: Syncfusion.Maui.DataGrid
Assembly: Syncfusion.Maui.DataGrid.dll
Syntax
public class DataGridTimePickerCellRenderer : DataGridCellRenderer<SfDataGridLabel, SfTimePicker>, IDataGridCellRenderer, IDisposable
Constructors
DataGridTimePickerCellRenderer()
Initializes a new instance of the DataGridTimePickerCellRenderer class.
Declaration
public DataGridTimePickerCellRenderer()
Methods
BeginEdit(RowColumnIndex, DataGridCell, DataGridColumn, object)
Override BeginEdit to add a label control for displaying the selected time value alongside the picker.
Declaration
[UnconditionalSuppressMessage("Trimming", "IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code", Justification = "The OnInitializeEditView method is not trim compatible")]
public override bool BeginEdit(RowColumnIndex rowColumnIndex, DataGridCell cellElement, DataGridColumn column, object rowData)
Parameters
| Type | Name | Description |
|---|---|---|
| RowColumnIndex | rowColumnIndex | |
| DataGridCell | cellElement | |
| DataGridColumn | column | |
| object | rowData |
Returns
| Type |
|---|
| bool |
Overrides
EndEdit(DataColumnBase, object, bool)
Override EndEdit to properly remove the label control from the cell.
Declaration
public override bool EndEdit(DataColumnBase dataColumn, object record, bool canResetBinding = false)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| object | record | |
| bool | canResetBinding |
Returns
| Type |
|---|
| bool |
Overrides
GetControlValue()
Gets the current cell value
Declaration
[RequiresUnreferencedCode("The GetControlValue method is not trim compatible")]
public override object? GetControlValue()
Returns
| Type |
|---|
| object |
Overrides
OnCreateEditUIView()
Creates a new edit UI view for the data grid cell.
Declaration
protected override SfTimePicker OnCreateEditUIView()
Returns
| Type |
|---|
| SfTimePicker |
Overrides
OnInitializeDisplayView(DataColumnBase, SfDataGridLabel?)
Initializes the display view for the cell.
Declaration
protected override void OnInitializeDisplayView(DataColumnBase dataColumn, SfDataGridLabel? displayView)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfDataGridLabel | displayView |
Overrides
OnInitializeEditView(DataColumnBase, SfTimePicker)
Initializes the edit view for the cell.
Declaration
[RequiresUnreferencedCode("The OnInitializeEditView method is not trim compatible")]
public override void OnInitializeEditView(DataColumnBase dataColumn, SfTimePicker timePicker)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfTimePicker | timePicker |
Overrides
OnUpdateCellValue(DataColumnBase)
Updates the cell value of the column.
Declaration
protected override void OnUpdateCellValue(DataColumnBase dataColumn)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn |
Overrides
SetControlValue(object)
Sets the current cell value
Declaration
public override void SetControlValue(object value)
Parameters
| Type | Name | Description |
|---|---|---|
| object | value |
Overrides
UnwireEditUIElement(SfTimePicker)
Unwires the edit element events
Declaration
protected override void UnwireEditUIElement(SfTimePicker editElement)
Parameters
| Type | Name | Description |
|---|---|---|
| SfTimePicker | editElement |
Overrides
UpdateEditViewCellStyle(DataColumnBase, SfTimePicker)
Updates the style of the edit view
Declaration
protected override void UpdateEditViewCellStyle(DataColumnBase dataColumn, SfTimePicker timePicker)
Parameters
| Type | Name | Description |
|---|---|---|
| DataColumnBase | dataColumn | |
| SfTimePicker | timePicker |