Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Android has a built-in overlay to handle two common scenarios:
All you need to do is create a MyLocationOverlay instance, add it to your MapView’s list of overlays, and enable and disable the desired features at appropriate times.
The “at appropriate times” notion is for maximizing battery life. There is no sense in updating locations or directions when the activity is paused, so it is recommended that you enable these features in onResume() and disable them in onPause().
For example, NooYawk will display a compass rose using MyLocationOverlay. To do this, we first need to create the overlay and add it to the list of overlays (where me is the MyLocationOverlay instance as a private data member):