blob: 9d16978baa2fab3b26083f7450fb03cd325001b3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#import "SimpleMapViewExample.h"
@import Mapbox;
NSString *const MBXExampleSimpleMapView = @"SimpleMapViewExample";
@implementation SimpleMapViewExample
- (void)viewDidLoad {
[super viewDidLoad];
MGLMapView *mapView = [[MGLMapView alloc] initWithFrame:self.view.bounds];
mapView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
// Set the map’s center coordinate and zoom level.
[mapView setCenterCoordinate:CLLocationCoordinate2DMake(59.31, 18.06)
zoomLevel:9
animated:NO];
[self.view addSubview:mapView];
}
@end
|