MouseRegionModifier constructor

const MouseRegionModifier({
  1. Key? key,
  2. Widget? child,
  3. Key? modifierKey,
  4. PointerEnterEventListener? onEnter,
  5. PointerExitEventListener? onExit,
  6. PointerHoverEventListener? onHover,
  7. MouseCursor cursor = MouseCursor.defer,
  8. bool opaque = true,
  9. HitTestBehavior? hitTestBehavior,
})

Creates a widget that forwards mouse events to callbacks.

By default, all callbacks are empty, cursor is MouseCursor.defer, and opaque is true. The cursor must not be null.

Implementation

const MouseRegionModifier({
  super.key,
  super.child,
  super.modifierKey,
  this.onEnter,
  this.onExit,
  this.onHover,
  this.cursor = MouseCursor.defer,
  this.opaque = true,
  this.hitTestBehavior,
});