Class DataGridCheckBoxSelectorCellRenderer
A cell renderer that displays checkboxes for row selection in a DataGridCheckBoxSelectorColumn. Implements bidirectional synchronization with the DataGrid's selection controller.
Inheritance
Inherited Members
Namespace: Syncfusion.Maui.DataGrid
Assembly: Syncfusion.Maui.DataGrid.dll
Syntax
public class DataGridCheckBoxSelectorCellRenderer : DataGridCellRenderer<StackLayout, View>, IDataGridCellRenderer, IDisposable
Constructors
DataGridCheckBoxSelectorCellRenderer()
Initializes a new instance of the DataGridCheckBoxSelectorCellRenderer class.
Declaration
public DataGridCheckBoxSelectorCellRenderer()
Methods
OnCreateDisplayUIView()
Creates the display view (checkbox) for a data row or header.
Declaration
protected override StackLayout OnCreateDisplayUIView()
Returns
| Type |
|---|
| Microsoft.Maui.Controls.StackLayout |
Overrides
OnCreateEditUIView()
Creates the edit view (same as display view since checkbox is not editable).
Declaration
protected override View OnCreateEditUIView()
Returns
| Type |
|---|
| Microsoft.Maui.Controls.View |
Overrides
OnInitializeDisplayView(DataColumnBase, StackLayout)
Initializes the display view (called when rendering a data row cell). This renderer only handles data rows. Headers are handled by DataGridCheckBoxSelectorHeaderCellRenderer. Selection synchronization is now handled via RaiseSelectionChangedEvent interception in the DataGrid class.
Declaration
protected override void OnInitializeDisplayView(DataColumnBase dataColumn, StackLayout view)
Parameters
| Type | Name | Description |
|---|---|---|
| Syncfusion.Maui.DataGrid.DataColumnBase | dataColumn | |
| Microsoft.Maui.Controls.StackLayout | view |
Overrides
OnUnloadViews(DataColumnBase)
Unloads the views and unsubscribes from events to prevent memory leaks and stale event handlers.
Declaration
protected override void OnUnloadViews(DataColumnBase dataColumn)
Parameters
| Type | Name | Description |
|---|---|---|
| Syncfusion.Maui.DataGrid.DataColumnBase | dataColumn |
Overrides
OnUpdateCellValue(DataColumnBase)
Updates the cell value when the underlying data changes. This is called by the DataGrid when refreshing cells.
Declaration
protected override void OnUpdateCellValue(DataColumnBase dataColumn)
Parameters
| Type | Name | Description |
|---|---|---|
| Syncfusion.Maui.DataGrid.DataColumnBase | dataColumn |