Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- - (BOOL)mapView:(GMSMapView *)mapView didTapMarker:(GMSMarker *)marker {
- if (marker.userData) {
- Property *property = marker.userData;
- [[MessagesManager sharedInstance] showSpinner:self.view];
- ...
- return YES;
- } else {
- return NO;
- }
- }
- if ([_points count]) {
- GMSMutablePath *rect = [GMSMutablePath path];
- [rect addCoordinate:_startDrawingPoint];
- for (id location in _points) {
- float lat = [[[_points objectForKey:location] valueForKey:@"lat"] floatValue],
- lng = [[[_points objectForKey:location] valueForKey:@"lng"] floatValue];
- CLLocationCoordinate2D coordinate = CLLocationCoordinate2DMake(lat, lng);
- [rect addCoordinate:coordinate];
- }
- GMSPolygon *polygon = [GMSPolygon polygonWithPath:rect];
- polygon.fillColor = [UIColor colorWithRed:0.25 green:0 blue:0 alpha:0.05];
- polygon.strokeColor = [UIColor blackColor];
- polygon.strokeWidth = 2;
- polygon.map = _mapView;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement