lifecycle icon indicating copy to clipboard operation
lifecycle copied to clipboard

ChildPageLifecycleWrapper 包裹的widget,with了LifecycleAware,收不到生命周期回调

Open weyyan opened this issue 10 months ago • 3 comments

代码如

PageViewLifecycleWrapper( // Outer PageView

        child: PageView(
          controller: pageController,
          physics: NeverScrollableScrollPhysics(),
          children: [
            FixedChildPageLifecycleWrapper(
              index: 0,
              wantKeepAlive: true,child: AWidget()),
class AWdiget extends StatefulWidget {
  createState() => _State();
}
class _State<T extends StatefulWidget> extends State<T>
    with LifecycleAware, LifecycleMixin<T>,

如果是单独push这个widget是能收到回调的

weyyan avatar Mar 27 '25 13:03 weyyan