Skip to content

Instantly share code, notes, and snippets.

@oskosk
Created July 18, 2013 00:56
Show Gist options
  • Save oskosk/6025900 to your computer and use it in GitHub Desktop.
Save oskosk/6025900 to your computer and use it in GitHub Desktop.
función para agregar la capa googleroadmap a un mapa normal de argenmap.jquery v1. (que por default muestra solo la capa base argenmap y como alternativa, el mapa SATELLITE de Google Maps API con la capa transparente de argenmap y no con los topónimos de Google
function argenmap_agregarGoogleRoadmap()
{
var gmap = $('#map').data('gmap');
gmap.mapTypeControlOptions.mapTypeIds.push('roadmap');
gmap.setOptions({
mapTypeControlOptions: {
mapTypeIds: gmap.mapTypeControlOptions.mapTypeIds,
style: google.maps.MapTypeControlStyle.DROPDOWN_MENU
}
});
function resetLabel() {
gmap.mapTypes.roadmap.name='Mapa de Google';
gmap.setOptions({'mapTypeControl':true});
}
google.maps.event.addListenerOnce(gmap,'idle',resetLabel);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment