我是 google map sdk for ios 的新手。我在视图上添加了一张地图。当我进入这个 mapView 时,我想定位自己。所以我写道:
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:-33.8683
longitude:151.2086
zoom:6];
_iMapView = [GMSMapView mapWithFrame:CGRectMake(0, 0, 320, 480) camera:camera];
self.iMapView.myLocationEnabled = YES;
self.iMapView.delegate=self;
GMSMarkerOptions *annotation = [[GMSMarkerOptions alloc] init];
annotation.position = CLLocationCoordinate2DMake(-33.8683, 151.2086);
annotation.title = @"Sydney";
annotation.snippet = @"Australia";
//annotation.infoWindowAnchor=CGPointMake(0.5, 0.5);
[self.iMapView addMarkerWithOptions:annotation];
//[self.view addSubview:self.iMapView];
self.view=self.iMapView;
但是我在坐标(33.8683,151.2086)中找到了mapView视图,我只想将mapView移动到wyposition。我还发现谷歌没有回调函数参考
self.iMapView.myLocationEnabled = YES;
谢谢你的回复。