diff options
Diffstat (limited to 'platform/ios/src')
-rw-r--r-- | platform/ios/src/MGLMapView.h | 8 | ||||
-rw-r--r-- | platform/ios/src/MGLMapView.mm | 49 |
2 files changed, 6 insertions, 51 deletions
diff --git a/platform/ios/src/MGLMapView.h b/platform/ios/src/MGLMapView.h index 3ce8641bc0..bfe3beb3b8 100644 --- a/platform/ios/src/MGLMapView.h +++ b/platform/ios/src/MGLMapView.h @@ -286,13 +286,13 @@ MGL_EXPORT IB_DESIGNABLE */ - (IBAction)showAttribution:(id)sender; -@property (nonatomic) NS_ARRAY_OF(NSString *) *styleClasses __attribute__((unavailable("This property is non-functional."))); +@property (nonatomic) NS_ARRAY_OF(NSString *) *styleClasses __attribute__((unavailable("Support for style classes has been removed."))); -- (BOOL)hasStyleClass:(NSString *)styleClass __attribute__((unavailable("This method is non-functional."))); +- (BOOL)hasStyleClass:(NSString *)styleClass __attribute__((unavailable("Support for style classes has been removed."))); -- (void)addStyleClass:(NSString *)styleClass __attribute__((unavailable("This method is non-functional."))); +- (void)addStyleClass:(NSString *)styleClass __attribute__((unavailable("Support for style classes has been removed."))); -- (void)removeStyleClass:(NSString *)styleClass __attribute__((unavailable("This method is non-functional."))); +- (void)removeStyleClass:(NSString *)styleClass __attribute__((unavailable("Support for style classes has been removed."))); #pragma mark Displaying the User’s Location diff --git a/platform/ios/src/MGLMapView.mm b/platform/ios/src/MGLMapView.mm index 0475e9325b..b7d0974872 100644 --- a/platform/ios/src/MGLMapView.mm +++ b/platform/ios/src/MGLMapView.mm @@ -249,8 +249,6 @@ public: BOOL _opaque; - NS_MUTABLE_ARRAY_OF(NSURL *) *_bundledStyleURLs; - MGLAnnotationTagContextMap _annotationContextsByAnnotationTag; MGLAnnotationObjectTagMap _annotationTagsByAnnotation; @@ -3489,11 +3487,6 @@ public: return mbgl::Projection::getMetersPerPixelAtLatitude(latitude, self.zoomLevel); } -- (CLLocationDistance)metersPerPixelAtLatitude:(CLLocationDegrees)latitude -{ - return [self metersPerPointAtLatitude:latitude]; -} - #pragma mark - Camera Change Reason - - (void)resetCameraChangeReason @@ -3501,40 +3494,6 @@ public: self.cameraChangeReasonBitmask = MGLCameraChangeReasonNone; } -#pragma mark - Styling - - -- (NS_ARRAY_OF(NSURL *) *)bundledStyleURLs -{ - if ( ! _bundledStyleURLs) - { - _bundledStyleURLs = [NSMutableArray array]; - for (NSUInteger i = 0; i < mbgl::util::default_styles::numOrderedStyles; i++) - { - NSURL *styleURL = [NSURL URLWithString:@(mbgl::util::default_styles::orderedStyles[i].url)]; - [_bundledStyleURLs addObject:styleURL]; - } - } - - return [NSArray arrayWithArray:_bundledStyleURLs]; -} - -- (nullable NSString *)styleID -{ - [NSException raise:@"Method unavailable" format: - @"%s has been replaced by -[MGLMapView styleURL].", - __PRETTY_FUNCTION__]; - return nil; -} - -- (void)setStyleID:(nullable NSString *)styleID -{ - [NSException raise:@"Method unavailable" format: - @"%s has been replaced by -[MGLMapView setStyleURL:].\n\n" - @"If you previously set this style ID in a storyboard inspectable, select the MGLMapView in Interface Builder and delete the “styleID” entry from the User Defined Runtime Attributes section of the Identity inspector. " - @"Then go to the Attributes inspector and enter “mapbox://styles/%@” into the “Style URL” field.", - __PRETTY_FUNCTION__, styleID]; -} - #pragma mark - Annotations - - (nullable NS_ARRAY_OF(id <MGLAnnotation>) *)annotations @@ -4779,12 +4738,8 @@ public: userLocationAnnotationView = (MGLUserLocationAnnotationView *)[self.delegate mapView:self viewForAnnotation:self.userLocation]; if (userLocationAnnotationView && ! [userLocationAnnotationView isKindOfClass:MGLUserLocationAnnotationView.class]) { - static dispatch_once_t onceToken; - dispatch_once(&onceToken, ^{ - NSLog(@"Ignoring user location annotation view with type %@. User location annotation view must be a kind of MGLUserLocationAnnotationView. This warning is only shown once and will become an error in a future version.", NSStringFromClass(userLocationAnnotationView.class)); - }); - - userLocationAnnotationView = nil; + [NSException raise:@"MGLUserLocationAnnotationTypeException" + format:@"User location annotation view must be a kind of MGLUserLocationAnnotationView. %@", userLocationAnnotationView.debugDescription]; } } |