我正在尝试在 iOS6 的 Google Map View 中加载地点。如何设置地图的框架?目前是全屏
-(void)loadView {
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:10.00989
longitude:76.316142
zoom:15];
mapView_ = [GMSMapView mapWithFrame:CGRectZero camera:camera];
self.view = mapView_;
}
我尝试在当前视图中创建一个新的(小)视图并在其中添加地图,但当时页面没有被加载。它显示一个全黑屏
-(void)loadView {
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:10.00989
longitude:76.316142
zoom:15];
mapView_ = [GMSMapView mapWithFrame:CGRectZero camera:camera];
[self.view Addsubview:newView];
self.newView = mapView_;
}