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

Improved map resizing #1061

Merged
merged 4 commits into from
May 30, 2022
Merged

Conversation

felix-mittermeier
Copy link
Contributor

Before this change it sometimes happened that the map did not fill the whole parent on web when it was resized, like in the following example:

Bildschirmfoto 2022-05-25 um 15 03 41

After these changes it works much more reliable when the browser window gets resized:

after.mov

Besides that it also improves the performance a bit because previously the _map.resize(); function was called every time the map style has loaded whereas now the internal _onMapResize();is called which first checks if the map has to be resized or not and only does it if is required.

mapbox_gl_web/pubspec.yaml Outdated Show resolved Hide resolved
pubspec.yaml Outdated Show resolved Hide resolved
Copy link
Collaborator

@felix-ht felix-ht left a comment

Choose a reason for hiding this comment

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

LGTM

@felix-ht felix-ht merged commit b1479f4 into flutter-mapbox-gl:master May 30, 2022
FreeGrow added a commit to FreeGrow/maps that referenced this pull request Sep 21, 2023
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