constrainToViewport property

  1. @override
set constrainToViewport (bool constrainToViewport)
override

Sets whether the popup should be constrained to the viewport.

If this is true, then the popup's positioned will be clamped to always be within the viewport instead of moving off-screen.

Implementation

@override
set constrainToViewport(bool constrainToViewport) {
  state.constrainToViewport = constrainToViewport;
}