summaryrefslogtreecommitdiff
path: root/platform/ios/app/MBXViewController.m
diff options
context:
space:
mode:
authorJesse Bounds <jesse@rebounds.net>2017-04-04 15:25:59 -0700
committerGitHub <noreply@github.com>2017-04-04 15:25:59 -0700
commitff7337121685b1ff091468dc96cfc23e567ab029 (patch)
tree5a7d99a4fb5d97c3b7309cad4fcd11b6db84a47f /platform/ios/app/MBXViewController.m
parente34b4718422438af365fe5ede67d1c490e95d9cc (diff)
downloadqtlocation-mapboxgl-ff7337121685b1ff091468dc96cfc23e567ab029.tar.gz
[ios] Silence incompatible type warning for callout view (#8608)
This silences a compatibility warning that was introduced in a previous refactor that changed the return type of the callout view for annotation delegate method. This also adds checks to ensure that the callout view provided by the delegate to the map view is of the correct type and conforms to the correct protocol.
Diffstat (limited to 'platform/ios/app/MBXViewController.m')
-rw-r--r--platform/ios/app/MBXViewController.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/ios/app/MBXViewController.m b/platform/ios/app/MBXViewController.m
index 39458c4f31..25eb598231 100644
--- a/platform/ios/app/MBXViewController.m
+++ b/platform/ios/app/MBXViewController.m
@@ -1739,7 +1739,7 @@ typedef NS_ENUM(NSInteger, MBXSettingsMiscellaneousRows) {
}];
}
-- (UIView<MGLCalloutView> *)mapView:(__unused MGLMapView *)mapView calloutViewForAnnotation:(id<MGLAnnotation>)annotation
+- (nullable id <MGLCalloutView>)mapView:(__unused MGLMapView *)mapView calloutViewForAnnotation:(id<MGLAnnotation>)annotation
{
if ([annotation respondsToSelector:@selector(title)]
&& [annotation isKindOfClass:[MBXCustomCalloutAnnotation class]])