DataRow2 class
Extension of standard DataRow, adds row level tap events. Also there're onSecondaryTap and onSecondaryTapDown which are not available in DataCells and which can be useful in Desktop settings when a reaction to the right click is required.
Constructors
-
DataRow2({LocalKey? key, bool selected = false, ValueChanged<
bool?> ? onSelectChanged, MaterialStateProperty<Color?> ? color, required List<DataCell> cells, double? specificRowHeight, GestureTapCallback? onTap, GestureTapCallback? onDoubleTap, GestureLongPressCallback? onLongPress, GestureTapCallback? onSecondaryTap, GestureTapDownCallback? onSecondaryTapDown}) -
Creates the configuration for a row of a DataTable2.
const
-
DataRow2.byIndex({int? index, bool selected = false, ValueChanged<
bool?> ? onSelectChanged, MaterialStateProperty<Color?> ? color, required List<DataCell> cells, double? specificRowHeight, GestureTapCallback? onTap, GestureTapCallback? onDoubleTap, GestureLongPressCallback? onLongPress, GestureTapCallback? onSecondaryTap, GestureTapDownCallback? onSecondaryTapDown})
Properties
-
cells
→ List<
DataCell> -
The data for this row.
finalinherited
-
color
→ MaterialStateProperty<
Color?> ? -
The color for the row.
finalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → LocalKey?
-
A Key that uniquely identifies this row. This is used to
ensure that if a row is added or removed, any stateful widgets
related to this row (e.g. an in-progress checkbox animation)
remain on the right row visually.
finalinherited
-
mouseCursor
→ MaterialStateProperty<
MouseCursor?> ? -
The cursor for a mouse pointer when it enters or is hovering over the
data row.
finalinherited
- onDoubleTap → GestureTapCallback?
-
Row double tap handler, won't be called if tapped cell has any tap event handlers
final
- onLongPress → GestureLongPressCallback?
-
Called if the row is long-pressed.
finalinherited
- onSecondaryTap → GestureTapCallback?
-
Row right click handler, won't be called if tapped cell has any tap event handlers
final
- onSecondaryTapDown → GestureTapDownCallback?
-
Row right mouse down handler, won't be called if tapped cell has any tap event handlers
final
-
onSelectChanged
→ ValueChanged<
bool?> ? -
Called when the user selects or unselects a selectable row.
finalinherited
- onTap → GestureTapCallback?
-
Row tap handler, won't be called if tapped cell has any tap event handlers
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- selected → bool
-
Whether the row is selected.
finalinherited
- specificRowHeight → double?
-
Specific row height, which will be used only if provided.
If not provided, dataRowHeight will be applied.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited