Logo Icon Logo
A Crowd-sourced Cookbook on Writing Great Android Apps
GitHub logo Twitter logo OReilly Book Cover Art
Changing Views of a MapView.Back to Android Cookbook Home | Up to Chapter: Location and Map Applications

Author: Rachee Singh ('racheesingh')
In Published Edition? No
FormatLanguage: WikiFormat

Changing Views of a MapView.


Showing an appropriate view of a MapView based on the context in the application.


Changing the View of a map from the default map mode to satellite or street mode.


Warning The Google Maps V1 API is deprecated; new code should use the V2 API discussed in Recipes 4285 and 4297.

If the application needs to display distance information between 2 locations on the map, then keeping the map in Street mode is more suitable. Similarly, some applications might need to use the Satellite view of Google maps. This can be done programmatically by:

//For street view

//For satellite view

See Also