I can enable a myLocation View in the new Maps Api through setMyLocationEnabled.
The first version of the Api had a Method runOnFirstFix that enabled me to animate the map to the users location once the location is found. I can not find a listener or location like that in the Api Version 2.
Is there a solution to execute an action once the user is located?
Google Maps Android API V2 has a LocationSource. From the docs:
“A GoogleMap object has a built-in location provider for its my-location layer, but it can be replaced with another one that implements this interface.”
LocationSource
I imagine you’ll need to use that in conjunction with a LocationSource.OnLocationChangedListener
Update
Figured it out. If you want to do something similar to runOnFirstFix, here’s a basic example that waits until the User’s location is available, then animates the map to center on their location.
Update 2
If you’re interested in centering the map on the user’s location when their location goes off screen (like MyLocationOverlay does in the old API), see this answer
or this blog post: Google Maps Android API V2 MyLocation LocationSource and event handling