Last active
December 19, 2015 22:18
-
-
Save oskosk/6025887 to your computer and use it in GitHub Desktop.
función para superponer imagen de las Islas Malvinas sobre google roadmap con argenmap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function argenmap_superponerIslasMalvinasSobreGoogleRoadmap() | |
{ | |
var gmap = $('#map').data('gmap'); | |
if (! window.oldmap) { | |
var boundaries = new google.maps.LatLngBounds( | |
new google.maps.LatLng(-52.449314, -61.391602), | |
new google.maps.LatLng(-50.965346, -56.414795) | |
); | |
oldmap = new google.maps.GroundOverlay('//www.desarrollosocial.gov.ar/Images/MalvinasArgentinas2.png',boundaries); | |
} | |
google.maps.event.addListener( gmap, "maptypeid_changed", function(){ | |
if ( $gmap.getMapTypeId() == 'roadmap' ) { | |
oldmap.setMap(gmap); | |
} else { | |
oldmap.setMap(null); | |
} | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment