summaryrefslogtreecommitdiff
path: root/platform/ios/app/MBXCustomCalloutView.m
diff options
context:
space:
mode:
authorFredrik Karlsson <bjorn.fredrik.karlsson@gmail.com>2017-01-09 17:24:07 +0100
committerMinh Nguyễn <mxn@1ec5.org>2017-01-11 15:48:08 -0800
commitf1fc9bdfeb9ba107d27242ee4618228c204e98a3 (patch)
treeb19ffb83b632cdb4d1b2539be8045c8b370d0293 /platform/ios/app/MBXCustomCalloutView.m
parent57644b2804a3d27ff19a58e0f3015d83264833ab (diff)
downloadqtlocation-mapboxgl-f1fc9bdfeb9ba107d27242ee4618228c204e98a3.tar.gz
[ios] Optional positioning and stickiness for callout view
Diffstat (limited to 'platform/ios/app/MBXCustomCalloutView.m')
-rw-r--r--platform/ios/app/MBXCustomCalloutView.m7
1 files changed, 7 insertions, 0 deletions
diff --git a/platform/ios/app/MBXCustomCalloutView.m b/platform/ios/app/MBXCustomCalloutView.m
index 9edc00f6e9..e46b727d84 100644
--- a/platform/ios/app/MBXCustomCalloutView.m
+++ b/platform/ios/app/MBXCustomCalloutView.m
@@ -17,6 +17,8 @@ static CGFloat const tipWidth = 10.0;
}
@synthesize representedObject = _representedObject;
+@synthesize anchoredToAnnotation = _anchoredToAnnotation;
+@synthesize dismissesAutomatically = _dismissesAutomatically;
@synthesize leftAccessoryView = _leftAccessoryView;
@synthesize rightAccessoryView = _rightAccessoryView;
@synthesize delegate = _delegate;
@@ -66,6 +68,11 @@ static CGFloat const tipWidth = 10.0;
}
}
+- (void)setCenter:(CGPoint)center {
+ center.y = center.y - CGRectGetMidY(self.bounds);
+ [super setCenter:center];
+}
+
- (void)dismissCalloutAnimated:(BOOL)animated
{
if (self.superview)