
');
addInfoWindow(mms, false, '
Monroe Middle School
1055 S Monroe St, San Jose, CA 95128
');
addInfoWindow(rhms, false, '
Rolling Hills Middle School
1585 More Ave, Los Gatos, CA 95032
');
addInfoWindow(cms, false, '
Campbell School of Innovation
1295 Cherry Ln, Campbell, CA 95008
');
addInfoWindow(blk, false, '
Blackford Elementary School
1970 Willow St, San Jose, CA 95125
');
addInfoWindow(cpr, false, '
Capri Elementary School
850 Chapman Dr, Campbell, CA 95008
');
addInfoWindow(cst, false, '
Castlemont Elementary School
3040 Payne Ave, Campbell, CA 95008
');
addInfoWindow(fhl, false, '
Forest Hill Elementary School
4450 McCoy Ave, San Jose, CA 95130
');
addInfoWindow(lyn, false, '
Lynhaven Elementary School
881 S Cypress Ave, San Jose, CA 951170
');
addInfoWindow(mln, false, '
Marshall Lane Elementary School
14114 Marilyn Ln, Saratoga, CA 95070
');
addInfoWindow(rsm, false, '
Rosemary Elementary School
401 W Hamilton Ave, Campbell, CA 95008
');
addInfoWindow(sks, false, '
Sherman Oaks Community Charter School
1800-C Fruitdale Ave, San Jose, CA 95128
');
addInfoWindow(vlg, false, '
Village School
825 West Parr Ave, Campbell, CA 95008
');
addInfoWindow(flc, false, '
Family Learning Center
401 W Hamilton Ave, Campbell, CA 95008
');
addInfoWindow(plc, false, '
Professional Learning Center
1055 S Monroe St, San Jose, CA 95128
ext 5075
');
if (wwidth > 422){
voffset = 0;
zadj = 0;
}
if (wwidth > 682) {
voffset = 0.01;
}
if (wwidth > 777) {
voffset = 0.015;
}
if (wwidth > 1222) {
voffset = 0.005;
}
var listener = google.maps.event.addListener(map, "idle", function() {
var bounds = map.getBounds();
var sw = bounds.getSouthWest();
var ne = bounds.getNorthEast();
var half = ((sw.lat()-ne.lat())/2) + ne.lat() + voffset;
var westpoint = new google.maps.LatLng(half, -
6174318+zadj);
var eastpoint = new google.maps.LatLng(half, -
3825685-zadj);
var bound = new google.maps.LatLngBounds();
bound.extend( westpoint );
bound.extend( eastpoint );
map.fitBounds(bound);
google.maps.event.removeListener(listener);
});
// Initialize the layer
if (wwidth > 515){
var layer = new google.maps.FusionTablesLayer(tableid);
layer.setMap(map);
// Create the legend and display on the map
var legendDiv = document.createElement('DIV');
var legend = new Legend(legendDiv, map);
legendDiv.index = 1;
map.controls[google.maps.ControlPosition.LEFT_CENTER].push(legendDiv);
}
}
function Legend(controlDiv, map) {
// Set CSS styles for the DIV containing the control
// Setting padding to 5 px will offset the control
// from the edge of the map
controlDiv.style.padding = '5px';
// Set CSS for the control border
var controlUI = document.createElement('DIV');
controlUI.style.backgroundColor = 'rgba(255,255,255,.8)';
controlUI.style.borderStyle = 'solid';
controlUI.style.borderColor = 'rgba(0,0,0,.3)';
controlUI.style.borderWidth = '1px';
controlUI.style.padding = '6px';
controlUI.title = 'Legend';
controlDiv.appendChild(controlUI);
// Set CSS for the control text
var controlText = document.createElement('DIV');
controlText.style.fontFamily = 'Arial,sans-serif';
controlText.style.fontSize = '16px';
controlText.style.paddingLeft = '4px';
controlText.style.paddingRight = '4px';
// Add the text
controlText.innerHTML = '
Our Schools' +
'
District Office' +
'
Blackford' +
'
Campbell (CSI)' +
'
Capri' +
'
Castlemont' +
'
Forest Hill' +
'
Lynhaven' +
'
Marshall Lane' +
'
Monroe' +
'
Rolling Hills' +
'
Rosemary' +
'
Sherman Oaks' +
'
Village' +
'
FLC' +
'
PLC';
controlUI.appendChild(controlText);
}
function myClick(id){
event.preventDefault();
google.maps.event.trigger(markers[id], 'click');
}
function loadScript() {
var script = document.createElement('script');
script.type = 'text/javascript';
script.src = 'https://maps.googleapis.com/maps/api/js?key=AIzaSyBEmrlVqHUjzYzrhL9JfH0VKYew3HvdCOs&' +
'callback=initialize';
document.body.appendChild(script);
document.getElementById("map_canvas").addEventListener("touchstart", thisTouchStart, true);
document.getElementById("map_canvas").addEventListener("touchend", thisTouchEnd, true);
document.getElementById("map_canvas").addEventListener("touchmove", thisTouchMove, true);
}
window.onload = loadScript;