paintMask method
draw crop layer lines
Implementation
void paintMask(
Canvas canvas, Size size, ExtendedImageCropLayerPainter painter) {
final Rect rect = Offset.zero & size;
final Rect cropRect = painter.cropRect;
final Color maskColor = painter.maskColor;
canvas.saveLayer(rect, Paint());
canvas.drawRect(
rect,
Paint()
..style = PaintingStyle.fill
..color = maskColor);
canvas.drawRect(cropRect, Paint()..blendMode = BlendMode.clear);
canvas.restore();
}