Created
January 26, 2017 12:33
-
-
Save here-devblog-gists/c103eb25c139f4219938c9405cd83c3d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func mapView(_ mapView: NMAMapView!, didReceiveLongPressAtLocation location: CGPoint) { | |
map = mapView | |
if NMAPositioningManager.shared().currentPosition != nil && NMAPositioningManager.shared().currentPosition.isValid { | |
calculateRoute(from: NMAPositioningManager.shared().currentPosition.coordinates, to: mapView.geoCoordinates(from: location)) | |
} else { | |
print("No valid startposition found") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment