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

Apply stronger typing of FlutterMap4 more broadly and opportunistic cleanup/fix #1515

Merged
merged 1 commit into from
May 12, 2023

Conversation

ignatz
Copy link
Contributor

@ignatz ignatz commented May 11, 2023

FlutterMap4 changes project()'s return type from CustomPoint to CustomPoint, henceforth push the stricter typing further up the stack and do some opportunistic cleanups/fixes.

…sentations to more conrcrete types. Mostly project now returns a typed CustomPoint<double>. Use that stronger-typing more consequently.
}

Bounds<double> getPixelBounds(double zoom) {
final mapZoom = zoom;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this to be a bug. It should have been:

final mapZoom = this.zoom;

Otherwise scale will always be 1.0 🤷

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting spot! Will have to test this just to make sure there's no side effects.

@JaffaKetchup
Copy link
Member

(Please pull from master. Only Flutter 3.10 is now supported.)

@JaffaKetchup JaffaKetchup self-requested a review May 12, 2023 08:49
Copy link
Member

@JaffaKetchup JaffaKetchup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks :)

@JaffaKetchup JaffaKetchup merged commit 0be5ecd into fleaflet:master May 12, 2023
@ignatz ignatz deleted the map_state_typing branch May 12, 2023 10:25
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 this pull request may close these issues.

2 participants