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

Can't change user's current location annotation view #213

Closed
av0c0der opened this issue May 9, 2017 · 6 comments
Closed

Can't change user's current location annotation view #213

av0c0der opened this issue May 9, 2017 · 6 comments
Assignees
Labels
feature New feature request. topic: location

Comments

@av0c0der
Copy link
Contributor

av0c0der commented May 9, 2017

Is it possible to change user's location tracking annotation view (circle with arrow shape inside)?

@1ec5
Copy link
Contributor

1ec5 commented May 9, 2017

RouteMapViewController is the NavigationMapView’s delegate (conforming to MGLMapViewDelegate). Since a map view can’t have multiple delegates, we need to plumb some additional MGLMapViewDelegate methods through RouteMapViewControllerDelegate, NavigationViewController, and NavigationViewControllerDelegate.

In particular, MGLMapViewDelegate.mapView(_:viewFor:) needs to be exposed as NavigationViewControllerDelegate.navigationViewController(_:mapView:viewFor:) so that the developer can implement their annotation view to replace the default. (We have an example of that implementation coming in mapbox/ios-sdk-examples#50.)

@av0c0der
Copy link
Contributor Author

@1ec5 will it also support changing user location annotation in navigation mode?

@av0c0der
Copy link
Contributor Author

av0c0der commented May 17, 2017

Can you please guide me where in the code the default shape for this annotation was set. Is this part of mapbox-navigation-ios or it is a part of MapboxDirections?

@1ec5
Copy link
Contributor

1ec5 commented May 17, 2017

will it also support changing user location annotation in navigation mode?

Yes.

Can you please guide me where in the code the default shape for this annotation was set.

The navigation SDK is currently using the default annotation image provided by the iOS map SDK (mapbox-gl-native).

@1ec5
Copy link
Contributor

1ec5 commented Aug 15, 2017

#498 would expose the delegate method for customizing the user location annotation view.

@bsudekum
Copy link
Contributor

This has been implemented.

wishtrip-dev pushed a commit to wishtrip-dev/mapbox-navigation-ios that referenced this issue Feb 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature request. topic: location
Projects
None yet
Development

No branches or pull requests

4 participants