choose the selected map

2.0
javi 12 years ago
parent 065e1a865d
commit 5bc89f08f9

@ -47,11 +47,16 @@ cdb.admin.MapTab = cdb.core.View.extend({
base_maps.append(this.baseLayerChooser.render().el);
//this.mapView = new cdb.geo.LeafletMapView({
this.mapView = new cdb.geo.GoogleMapsMapView({
var mapViewClass = cdb.geo.LeafletMapView;
if(this.map.get('provider') === 'googlemaps') {
mapViewClass = cdb.geo.GoogleMapsMapView;
}
this.mapView = new mapViewClass({
el: div,
map: this.map
});
this.map_enabled = true;
this.mapView.bind('newLayerView', self._bindDataLayer, self);

Loading…
Cancel
Save