CustomGestureDetector class
A custom gesture detector that provides visual feedback on user interaction.
This widget is a wrapper around InkWell and simplifies its usage by exposing common gesture callbacks and properties for customizing the visual feedback like splash color, hover color, and border radius.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- CustomGestureDetector
Constructors
-
CustomGestureDetector({Key? key, Widget? child, dynamic onTapDown(TapDownDetails)?, dynamic onTapUp(TapUpDetails)?, dynamic onTap()?, dynamic onTapCancel()?, dynamic onSecondaryTap()?, dynamic onSecondaryTapDown(TapDownDetails)?, dynamic onSecondaryTapUp(TapUpDetails)?, dynamic onSecondaryTapCancel()?, dynamic onTertiaryTapDown(TapDownDetails)?, BorderRadius? borderRadius, dynamic onTertiaryTapUp(TapUpDetails)?, dynamic onTertiaryTapCancel()?, dynamic onDoubleTapDown(TapDownDetails)?, dynamic onDoubleTap()?, dynamic onDoubleTapCancel()?, dynamic onLongPress()?, Color? hoverColor, Color? splashColor, WidgetStateProperty<
Color> ? overlayColor, Color? focusColor, double? borderRadiusDouble}) -
CustomGestureDetector constructor.
const
Properties
- borderRadius → BorderRadius?
-
The border radius of the containing rectangle.
This is used to clip the splash and highlight effects.
final
- borderRadiusDouble → double?
-
The radius for the circular border.
If
borderRadiusis also provided,borderRadiuswill be used.final - child → Widget?
-
The widget below this widget in the tree.
final
- focusColor → Color?
-
The color to use for the focus highlight.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hoverColor → Color?
-
The color to use for the hover highlight.
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- onDoubleTap → dynamic Function()?
-
a pointer for onDoubleTap
final
- onDoubleTapCancel → dynamic Function()?
-
a pointer for onDoubleTapCancel
final
- onDoubleTapDown → dynamic Function(TapDownDetails)?
-
a pointer for onDoubleTapDown
final
- onLongPress → dynamic Function()?
-
a pointer for onLongPress
final
- onSecondaryTap → dynamic Function()?
-
A tap with a secondary button has occurred.
final
- onSecondaryTapCancel → dynamic Function()?
-
The pointer that previously triggered onSecondaryTapDown will not end up
causing a tap.
final
- onSecondaryTapDown → dynamic Function(TapDownDetails)?
-
A pointer that might cause a secondary tap has contacted the screen at a
particular location.
final
- onSecondaryTapUp → dynamic Function(TapUpDetails)?
-
A pointer that will trigger a secondary tap has stopped contacting the
screen at a particular location.
final
- onTap → dynamic Function()?
-
A tap has occurred.
final
- onTapCancel → dynamic Function()?
-
The pointer that previously triggered onTapDown will not end up causing
a tap.
final
- onTapDown → dynamic Function(TapDownDetails)?
-
A pointer that might cause a tap has contacted the screen at a particular
location.
final
- onTapUp → dynamic Function(TapUpDetails)?
-
A pointer that detects up tap function
final
- onTertiaryTapCancel → dynamic Function()?
-
a pointer for tertiarytap cancel
final
- onTertiaryTapDown → dynamic Function(TapDownDetails)?
-
A pointer that might cause a tertiary tap has contacted the screen at a
particular location.
final
- onTertiaryTapUp → dynamic Function(TapUpDetails)?
-
A pointer that will trigger a tertiary tap has stopped contacting the
screen at a particular location.
final
-
overlayColor
→ WidgetStateProperty<
Color> ? -
The color of the overlay that appears when the user long-presses on the
widget.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- splashColor → Color?
-
The splash color of the ink response.
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited