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

feat: added set style method on controller #444

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

itheamc
Copy link

@itheamc itheamc commented Jun 6, 2024

No description provided.

@josxha josxha assigned kuhnroyal and unassigned kuhnroyal Jun 6, 2024
Copy link
Collaborator

@josxha josxha left a comment

Choose a reason for hiding this comment

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

Hi @itheamc, thank you for keeping your pull request updated with the main branch.

The user has the option to add annotations like circles, symbols and so on. After the user changes the style of the map the annotations added by the user should be still on the map to avoid an inconcistent state between flutter and the maplibre SDKs.

ios/Classes/MapboxMapController.swift Outdated Show resolved Hide resolved
lib/src/controller.dart Outdated Show resolved Hide resolved
Comment on lines 1165 to 1169
try {
_map.setStyle(styleString);
} on PlatformException catch (e) {
return Future.error(e);
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

When does _map.setStyle throw a PlatformException? (It's not used in the other methods.)

onMapCreated: _onMapCreated,
initialCameraPosition: const CameraPosition(target: LatLng(0.0, 0.0)),
onStyleLoadedCallback: onStyleLoadedCallback,
));
Copy link
Collaborator

Choose a reason for hiding this comment

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

Adding the option to change the map to this example could be confusing because this example showcases that the map style can in general be loaded from an local source. Could you create a new page that showcases this functionality please?

@josxha
Copy link
Collaborator

josxha commented Jun 23, 2024

Hi @itheamc, I've seen that you clicked on "Resolve conversations" for my comments but 4 haven't been implemented. Could you give some quick details what's the reason please?

@josxha josxha added this to the v0.20.1 milestone Oct 3, 2024
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.

3 participants