Created
April 29, 2013 03:04
-
-
Save Morse-Code/5479484 to your computer and use it in GitHub Desktop.
Revisions
-
Morse-Code created this gist
Apr 29, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,20 @@ - (IBAction)zoomToCurrentLocation:(id)sender { NSLog(@"zoomToCurrentLocation"); //Start updating location because we want it... [_myLocationManager startUpdatingLocation]; NSLog(@"lat: %f", _myLocationManager.location.coordinate.latitude); NSLog(@"long: %f", _myLocationManager.location.coordinate.longitude); MKCoordinateRegion viewRegion = MKCoordinateRegionMakeWithDistance(_myLocationManager.location.coordinate, defaultRange, defaultRange); [_dangerMap setRegion:viewRegion animated:YES]; //Stop updating location to save battery [_myLocationManager stopUpdatingLocation]; }