addToScene method
- SceneBuilder builder
override
Override this method to upload this layer to the engine.
Implementation
@override
void addToScene(ui.SceneBuilder builder) {
assert(clipRRect != null);
bool enabled = true;
assert(() {
enabled = !debugDisableClipLayers;
return true;
}());
if (enabled) {
engineLayer = builder.pushClipRRect(
clipRRect!,
clipBehavior: clipBehavior,
oldLayer: _engineLayer as ui.ClipRRectEngineLayer?,
);
} else {
engineLayer = null;
}
addChildrenToScene(builder);
if (enabled) {
builder.pop();
}
}