Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
2.5k views
in Technique[技术] by (71.8m points)

xcode - Custom info window in IOS google maps sdk

being a newby IOS developer, I'm really struggling to get something basic to work.

I have a need to display this kind of custom info window upon a marker click in the google maps sdk for ios.

enter image description here

Any help would be appreciated.

I've already seen the third party components, but even with them I cannot get this to display. There is always a title, snippet, left image and right image part. The real question is how do you get the gold star rating in the window, with the text next to it.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Make Xib as you want...set Text and image

set delegate GMSMapViewDelegate

-(UIView *)mapView:(GMSMapView *)mapView markerInfoWindow:(GMSMarker *)marker{

    CustomInfoWindow *infoWindow=[[[NSBundle mainBundle] loadNibNamed:@"InfoWindow" owner:self options:nil] objectAtIndex:0];  
     return infoWindow;

}

https://www.youtube.com/watch?v=ILiBXYscsyY for more help see this video..Uploded by google


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...