Add the missing canvas.save and canvas.restore (#18722)
This fixes https://github.com/flutter/flutter/issues/18708
This commit is contained in:
@@ -1752,8 +1752,10 @@ class RenderPhysicalShape extends _RenderPhysicalModelBase<Path> {
|
||||
);
|
||||
}
|
||||
canvas.drawPath(offsetPath, new Paint()..color = color..style = PaintingStyle.fill);
|
||||
canvas.save();
|
||||
canvas.clipPath(offsetPath);
|
||||
super.paint(context, offset);
|
||||
canvas.restore();
|
||||
assert(context.canvas == canvas, 'canvas changed even though needsCompositing was false');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user