Skip to content

Commit

Permalink
fully fixed map
Browse files Browse the repository at this point in the history
  • Loading branch information
leonardloo committed May 5, 2014
1 parent 9c6dd33 commit 7f71105
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
13 changes: 8 additions & 5 deletions Zame/Zame/MapViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ - (CLLocationManager *)locationManager
return _locationManager;
}


- (void)viewDidLoad
{
[super viewDidLoad];
Expand Down Expand Up @@ -88,6 +89,10 @@ - (void)viewDidLoad
longPress.minimumPressDuration = 1.0;
[_mapView addGestureRecognizer:longPress];





// Do clustering
_mapView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;

Expand All @@ -101,15 +106,11 @@ - (void)viewDidLoad
// Assemble pins people array
[self assembleAllPins];

// Create clusters (without animations on view load)
//
[self.clusterer clusterize:NO];

// Zoom to show all clusters/markers on the map
//
[self.clusterer zoomToAnnotationsBounds:self.clusterer.markers];



}

- (void)didReceiveMemoryWarning
Expand Down Expand Up @@ -317,6 +318,8 @@ -(void)assembleAllPins {
[self.clusterer addMarker:marker];
}];

[self.clusterer clusterize:YES];

}];
});
});
Expand Down
1 change: 1 addition & 0 deletions Zame/Zame/REMarkerClusterer.m
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,7 @@ - (void)mapViewWillStartLoadingMap:(MKMapView *)mapView

- (void)mapViewDidFinishLoadingMap:(MKMapView *)mapView
{

if ([_delegate respondsToSelector:@selector(mapViewDidFinishLoadingMap:)])
[_delegate mapViewDidFinishLoadingMap:mapView];
}
Expand Down

0 comments on commit 7f71105

Please sign in to comment.