Created
May 6, 2020 14:43
-
-
Save letsar/484532b378876ee4548fbb426f45d3bb to your computer and use it in GitHub Desktop.
Gap
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Gap extends LeafRenderObjectWidget { | |
const Gap( | |
this.mainAxisExtent, { | |
Key key, | |
}) : assert(mainAxisExtent != null && | |
mainAxisExtent >= 0 && | |
mainAxisExtent < double.infinity), | |
super(key: key); | |
final double mainAxisExtent; | |
@override | |
RenderObject createRenderObject(BuildContext context) { | |
return _RenderGap(mainAxisExtent: mainAxisExtent); | |
} | |
@override | |
void updateRenderObject(BuildContext context, _RenderGap renderObject) { | |
renderObject.mainAxisExtent = mainAxisExtent; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment