debugPaintPointers method

  1. @protected
void debugPaintPointers (PaintingContext context, Offset offset)
@protected

In debug mode, paints a rectangle if this render box has counted more pointer downs than pointer up events.

Called for every RenderBox when debugPaintPointersEnabled is true.

By default, events are not counted. For details on how to ensure that events are counted for your class, see debugHandleEvent.

Implementation

@protected
void debugPaintPointers(PaintingContext context, Offset offset) {
  assert(() {
    if (_debugActivePointers > 0) {
      final Paint paint = Paint()
       ..color = Color(0x00BBBB | ((0x04000000 * depth) & 0xFF000000));
      context.canvas.drawRect(offset & size, paint);
    }
    return true;
  }());
}