浏览代码

fix setstate after dispose

/main
siyao 3 年前
当前提交
f94fbfbe
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3
      com.unity.uiwidgets/Runtime/widgets/LottiePainter.cs

3
com.unity.uiwidgets/Runtime/widgets/LottiePainter.cs


public override Widget build(BuildContext context) {
if (_round != 0) {
WidgetsBinding.instance.addPostFrameCallback((_) => {
if (!mounted) {
return;
}
setState(() => {
_frame += Time.deltaTime;
if (_frame > widget._duration) {

正在加载...
取消
保存