Sorry, you need to enable JavaScript to visit this website.

Multiple Maps

Multiple Maps

Developers are not limited to attaching only a single map. You can put as many map objects as you want on the same page without any issues.

Sample use case: You want to display two independent maps in your app. The maps have different styles i.e. use different styles.

image

_

weak var secoundMap:TTMapView!
    let map = TTMapView(frame: CGRect.zero)
    self.secoundMap = map
    let customStyle = Bundle.main.path(forResource: "style", ofType: "json")
@property (nonatomic,weak) TTMapView* secoundMap;
    TTMapView *map = [[TTMapView alloc] initWithFrame:CGRectZero];
    self.secoundMap = map;
    NSString *customStyle = [NSBundle.mainBundle pathForResource:@"style" ofType:@"json"];
    [self.secoundMap setStylePath:customStyle];
    [self.mapView addSubview:self.secoundMap];