IntersectionObserverLayer constructor

IntersectionObserverLayer({
  1. required Size elementSize,
  2. required Offset paintOffset,
  3. required IntersectionChangeCallback onIntersectionChange,
})

Implementation

IntersectionObserverLayer(
    {required Size elementSize,
    required Offset paintOffset,
    required this.onIntersectionChange})
    : // TODO: This is zero for box element. For sliver element, this offset points to the start of the element which may be outside the viewport.
      _elementOffset = Offset.zero,
      _layerOffset = Offset.zero,
      _elementSize = elementSize,
      _paintOffset = paintOffset;