flutter_parallax icon indicating copy to clipboard operation
flutter_parallax copied to clipboard

toDouble Error

Open Johnblundon opened this issue 5 years ago • 0 comments

I'm trying to use Parallax.Inside for a list with Images in a container. These are network images passed into a container, the widget works and displays fine but I'm constantly getting an error.

I/flutter (12496): size: Size(321.3, 180.0) I/flutter (12496): This RenderObject had the following descendants (showing up to depth 5): I/flutter (12496): child: RenderConstrainedBox#34785 relayoutBoundary=up7 NEEDS-PAINT NEEDS-COMPOSITING-BITS-UPDATE I/flutter (12496): child: RenderSemanticsAnnotations#8d52f relayoutBoundary=up8 NEEDS-PAINT NEEDS-COMPOSITING-BITS-UPDATE I/flutter (12496): child: RenderImage#f6eb8 relayoutBoundary=up9 NEEDS-PAINT

and the debug is constantly displaying the error: I/flutter (12496): Another exception was thrown: NoSuchMethodError: The method 'toDouble' was called on null.

Using Parallax.outside with a scroll controller eliminates the "toDoube" error but does not function as well as the inside method.

Here is my code: Parallax.inside( child: Container( constraints: BoxConstraints(minWidth: 440.0), child: Image( height: 300, image: CachedNetworkImageProvider(url), fit: BoxFit.cover, ), ), mainAxisExtent: 220, )

Any help would be greatly appreciated.

Johnblundon avatar Sep 03 '19 14:09 Johnblundon