ThomasEcalle/bouncing_widget

[Improvement] Be able to scroll when touching a Bouncing Widget

istornz opened this issue · 6 comments

Hello!

First thanks for your amazing plugin!
I have a suggestion/improvement: it's actually impossible to scroll when touching a bouncing widget.
But on the Reflecty app it's possible (which use a kind of bouncing widget).

To reproduce:

  1. Create a scroll view with many Bouncing widget inside.
  2. Touch any Bouncing widget and keep holding it.
  3. Try to scroll down: it's impossible, you need to find an empty space and drag from this space to scroll.

If you have any idea, maybe I can help :)
Thanks in advance.

I have this same issue as well, would be great if we could get a fix for this

@jacksonw765 Apparently no solution for this. I have workable fork version of it.

Do you have any progress? @jacksonw765

If any future reader is interested in this, check out my fork.

It's not perfect, but seems to work OK.

I just permitted BouncingWidget to take a ScrollController, then replaced _onDragUpdate to:

_onDragUpdate(DragUpdateDetails details, BuildContext context) { final Offset touchPosition = details.globalPosition; _isOutside = _isOutsideChildBox(touchPosition); if (widget.scrollController != null) { (widget.scrollController as ScrollController).jumpTo( (widget.scrollController as ScrollController).offset - details.delta.dy); } }

Hope this helps!

Or you guys can check out another similar package that i have developed, flutter_bounceable

Feel free to check out another package that I have developed taking motivation from this package itself: flutter_bounce. Hope this will work out for all of us 😊