Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: TransformableBox should enable onTap Event Propagation to Child Widgets #31

Closed
AndersKlint opened this issue Mar 21, 2025 · 1 comment · Fixed by #32

Comments

@AndersKlint
Copy link
Contributor

Is your feature request related to a problem? Please describe.
When tapping inside the box, I want the child to catch the onTap event. In my case I show the box over a camera feed which supports onTaps to focus the camera on that point. If I tap inside the box, the underlying camera feed should catch that event.

Describe the solution you'd like

  • Either add shouldCaptureTapEvents parameter. True by default.
  • include tapDetails in the onTap callback of TransformableBox.

Describe alternatives you've considered
Maybe there's a solution around this? I tried wrapping the Transformable box in a GestureDetector, but it throws an exception as it excepts to be a direct ancestor of a stack. Moving the detector to the TransformableBox's doesn't work either, as it seems the box catches the tap events.

@AndersKlint AndersKlint changed the title Feature Request: Enable onTap Event Propagation to Child Widgets (flutter widget) Feature Request: Enable onTap Event Propagation to Child Widgets Mar 21, 2025
@AndersKlint AndersKlint changed the title Feature Request: Enable onTap Event Propagation to Child Widgets Feature Request: TransformableBox should enable onTap Event Propagation to Child Widgets Mar 21, 2025
@AndersKlint
Copy link
Contributor Author

I was able to achieve this behaviour with a small fix and opened a PR:
#32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant