Add a compass rose overlay to indicate which direction is north
This commit is contained in:
@@ -255,6 +255,18 @@ google.maps.event.addListener(marker, 'click', function() {
|
||||
// initialize the markers and regions
|
||||
initMarkers();
|
||||
initRegions();
|
||||
|
||||
var compassDiv = document.createElement('DIV');
|
||||
|
||||
compassDiv.style.padding = '5px';
|
||||
|
||||
var compassImg = document.createElement('IMG');
|
||||
compassImg.src="compass.png";
|
||||
compassDiv.appendChild(compassImg);
|
||||
|
||||
map.controls[google.maps.ControlPosition.TOP_RIGHT].push(compassDiv);
|
||||
|
||||
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
||||
BIN
web_assets/compass.png
Normal file
BIN
web_assets/compass.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 7.2 KiB |
Reference in New Issue
Block a user