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

Option to not show user location and option to not focus users location #127

Open
ziga-hvalec opened this issue Apr 22, 2024 · 3 comments
Open
Assignees
Labels
type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@ziga-hvalec
Copy link
Collaborator

We would only like to show some markers on the map and don't really want to show the users location

We also don't want to focus users location.

Right now when the map loads, we show our markers but then when users location comes in it automatically focuses on the user and not on the map.

It would be nice to be able to hide users location and also have an option to show it but not focus it.

@ziga-hvalec ziga-hvalec added triage me I really want to be triaged. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. labels Apr 22, 2024
@ArturoSalazarB16
Copy link
Contributor

Hi @ziga-hvalec, there's a couple of API's available in the mapViewController to:

  1. Disable the "My location" button -
    setMyLocationButtonEnabled: (isOn: boolean) => {
  2. Hide the user location -
    setMyLocationEnabled: (isOn: boolean) => {

    Can you please check if this achieves what you're trying to do?

The sample app has an option to showcase this (in the "Maps" menu).

Thanks,
Arturo

@ArturoSalazarB16 ArturoSalazarB16 removed the triage me I really want to be triaged. label Apr 24, 2024
@ArturoSalazarB16
Copy link
Contributor

Hi @ziga-hvalec, will be closing for now this but please feel free to re-open in case this doesn't suffice your use case.

@ziga-hvalec
Copy link
Collaborator Author

I'm not sure that setMyLocationEnabled works. Should this remove my location arrow? if so then it's not working. I call setMyLocationEnabled(false) inside onMapReady

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

3 participants