I want to show a small window on the click of info window in iphone google maps. I want that when the user will tap on the marker, info window will appear. And on the tap of that info window, another window should appear. In android, there is a OnInfoWindowClickListener method. What we have in iOS like that ?
Asked
Active
Viewed 1,965 times
-2
-
u mean callOutView of annotaion ??? – iPatel Mar 11 '13 at 11:16
-
1I found that after a little search. It is GMSMapViewDelegate's method didTapInfoWindowOfMarker :) – Hawk-Eye Mar 11 '13 at 11:24
2 Answers
2
where you adding Map,add
mapView_.delegate=self;
then use this
-(void)mapView:(GMSMapView *)mapView
didTapInfoWindowOfMarker:(GMSMarker *)marker{
//info window tapped
}

Hatem Alimam
- 9,968
- 4
- 44
- 56

user2115266
- 137
- 1
- 12
-
-
1Create a CGRect with the required frame dimensions and set the MapView frame with method `mapWithFrame:` and then add the mapview as main subview. Below is the code which explains all. `CGRect fr= CGRectMake(0, 44, 768, 960); mapView_ = [GMSMapView mapWithFrame:fr camera:camera]; mapView_.myLocationEnabled = YES; [self.view addSubview:mapView_];` – Hawk-Eye Mar 29 '13 at 05:47
0
in iOS a delegate method will be called in the case the user taps on the info window. Here is the documentation of the delegate.
/**
* Called after a marker's info window has been tapped.
*/
- (void)mapView:(GMSMapView *)mapView
didTapInfoWindowOfMarker:(id<GMSMarker>)marker;
As parameters you will receive the mapView instance and the object of the info window's marker. Don't forget to include the GMSMapViewDelegate.

Robert Weindl
- 1,092
- 1
- 10
- 30