Skip to content

GestureDetector: ScaleUpdateDetails should also contain a delta since scale is a superset of pan.Β #43833

@marcglasberg

Description

@marcglasberg

If you define both onPanUpdate and onScaleUpdate you get this error:

Incorrect GestureDetector arguments.
I/flutter ( 3574): Having both a pan gesture recognizer and a scale gesture recognizer is redundant; scale is a superset of pan. Just use the scale gesture recognizer.

But how? onPanUpdate tells you dx and dy from the last position. While onScaleUpdate tells you focalPoint and localFocalPoint with no initial position. There's no easy way to convert between them.

Or am I missing something?

Frankly, if onScaleUpdate is a superset of onPanUpdate it should contain at least the exact same fields as onPanUpdate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: qualityA truly polished experiencec: proposalA detailed proposal for a change to Flutterf: gesturesflutter/packages/flutter/gestures repository.frameworkflutter/packages/flutter repository. See also f: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions