Skip to content

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

Closed

Description

@av0c0der

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

Activity

  1. 1ec5 commented on May 9, 2017

    @1ec5
    Contributor

    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.)

  2. av0c0der commented on May 17, 2017

    @av0c0der
    Author

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

  3. av0c0der commented on May 17, 2017

    @av0c0der
    Author

    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?

  4. 1ec5 commented on May 17, 2017

    @1ec5
    Contributor

    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).

  5. added
    feature
    and removed on Jul 19, 2017
  6. 1ec5 commented on Aug 15, 2017

    @1ec5
    Contributor

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

  7. bsudekum commented on Aug 16, 2017

    @bsudekum
    Contributor

    This has been implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

featuretopic: location

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions