just_the_tooltip icon indicating copy to clipboard operation
just_the_tooltip copied to clipboard

Error when using inside a ListView

Open victorvuelma opened this issue 3 years ago • 0 comments

I noticed a problem in the use of this library when used with the area mode and the tooltip inside a ListView or a GridView on Flutter 2.10.1.

When the widget that contains the tooltip is activated and move to outside of ListView, its cause this error

FlutterError (setState() or markNeedsBuild() called during build. This ValueListenableBuilder<Widget?> widget cannot be marked as needing to build because the framework is already in the process of building widgets. A widget can be marked as needing to be built during the build phase only if one of its ancestors is currently building. This exception is allowed because the framework builds parent widgets before children, which means a dirty descendant will always be built. Otherwise, the framework might not visit this widget during this build phase.

Possible to reproduce on example: https://github.com/Nolence/just_the_tooltip/blob/main/example/lib/pages/tooltip_area_page.dart

victorvuelma avatar Feb 16 '22 20:02 victorvuelma