Search code examples
google-maps-api-3

How to disable 45 degree option in Google Maps Javascript API 3.x


I want remove the option for the user to put the map into 45 degree tilt mode from the satellite view. I can set the default tilt by calling setTilt(0) on the Map object, but when the map is displayed, and the user clicks on the Satellite option in upper right of map, it still shows the 45 degree option.

How can I eliminate the 45 degree option, and still have the user able to switch between road and satellite view.


Solution

  • I've done this by reimplementing the "mapTypeControl" manually. then you have control over exactly what is included.

    (I did this because there used to be no way of not includeing the Terrain option - but that has been fixed now. Its the same basic issue)

    Can use this example as a starting point: http://gmaps-samples-v3.googlecode.com/svn/trunk/controls/index.html