[ios] Restart user location heading updates on validation

Fixes #4668. Thanks to @JThramer for reporting.
This commit is contained in:
Jason Wray
2016-04-11 16:14:47 -04:00
parent c3bed1dab8
commit eda132d922
2 changed files with 7 additions and 0 deletions

View File

@@ -4,6 +4,8 @@ Mapbox welcomes participation and contributions from everyone. If you’d like
## master
- User location heading updates now resume properly when an app becomes active again. ([#4674](https://github.com/mapbox/mapbox-gl-native/pull/4674))
## 3.2.0
- If you’ve previously installed the SDK as a static framework, the installation workflow has changed to address issues when submitting your application to the App Store or installing it on a device. Upon upgrading to this version of the SDK, you’ll need to add Mapbox.bundle to the Copy Bundle Resources build phase and remove Mapbox.framework from the Embed Frameworks build phase. ([#4455](https://github.com/mapbox/mapbox-gl-native/pull/4455))

View File

@@ -3047,6 +3047,11 @@ mbgl::Duration MGLDurationInSeconds(NSTimeInterval duration)
self.locationManager.headingFilter = 5.0;
self.locationManager.delegate = self;
[self.locationManager startUpdatingLocation];
if (self.userTrackingMode == MGLUserTrackingModeFollowWithHeading)
{
[self.locationManager startUpdatingHeading];
}
}
else if ( ! shouldEnableLocationServices && self.locationManager)
{