mirror of
https://github.com/flame-engine/flame.git
synced 2025-11-02 11:43:19 +08:00
Adding FlameSpriteWidget
This commit is contained in:
@ -164,6 +164,8 @@ class Util {
|
||||
///
|
||||
/// This will create a [CustomPaint] widget using a [CustomPainter] for rendering the [Sprite]
|
||||
/// Be aware that the Sprite must have been loaded, otherwise it can't be rendered
|
||||
///
|
||||
/// @Deprecated('Use FlameSpriteWidget instead')
|
||||
widgets.CustomPaint spriteAsWidget(Size size, Sprite sprite) =>
|
||||
widgets.CustomPaint(size: size, painter: _SpriteCustomPainter(sprite));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user