var map1; var bounds1; var businesses1; var geocodes1; var cntGeocoded1 = 0; var directionsPanel1; var directions1; var focusedBusiness1; function generateMap1() { if (GBrowserIsCompatible() && document.getElementById("svmap_canvas1") != null) { geocoder1 = new GClientGeocoder(); geocoder1.setCache(null); var mapOptions = { mapTypes:[G_NORMAL_MAP] }; map1 = new GMap2(document.getElementById("svmap_canvas1"), mapOptions); var mapControl = new GMapTypeControl(); map1.addControl(mapControl); map1.addControl(new GSmallZoomControl3D()); map1.disableDoubleClickZoom(); map1.disableScrollWheelZoom(); bounds1 = new GLatLngBounds; map1.setCenter(new GLatLng(-16.290154,-63.588653), 5); var marker40 = new GIcon(); marker40.image = "http://thermalloys.com/components/com_svmap/markers/apartment-3.png"; marker40.iconSize = new GSize(32,37); marker40.iconAnchor = new GPoint(16,37); marker40.infoWindowAnchor = new GPoint(16,18.5); businesses1 = [[16,marker40,"Sandvik Argentine S.A.",-38.73635,-62.220154,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/argentina/sandvik-argentine-sa.html",""],[17,marker40,"Sandvik do Brasil S.A Ind. e Com.",-23.009232,-46.989401,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/brazil/sandvik-do-brasil-sa-ind-e-com.html",""],[18,marker40,"Consistec",-23.643548,-46.650786,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/brazil/consistec.html",""],[19,marker40,"Sandvik Chile S.A.",-22.484635,-68.915695,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/chile/sandvik-chile-sa.html",""],[20,marker40,"Sandvik Del Peru S.A.",-12.191038,-77.005601,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/peru/sandvik-del-peru-sa.html",""],[21,marker40,"Claude steier",10.483272,-66.859722,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/venezuela/claude-steier.html",""],[22,marker40,"Sanven Steel, C.A.",11.41257854635878,-69.66551899909973,'
',"/thermalloys/site/en/thermalloys-worldwide/south-america/venezuela/sanven-steel-ca.html",""],[86,marker40,"Marcel & Marcel Fábrica de Resistencias Eléctricas Ltda.",-16.290154,-63.588653,'
Bolivia
',"/thermalloys/site/en/thermalloys-worldwide/south-america/bolivia/marcel-a-marcel-fabrica-de-resistencias-electricas-ltda.html",""],[87,marker40,"Marcel & Marcel Fábrica de Resistencias Eléctricas Ltda.",-33.450371,-70.641411,'
Chile
',"/thermalloys/site/en/thermalloys-worldwide/south-america/bolivia/marcel-a-marcel-fabrica-de-resistencias-electricas-ltda.html",""],[88,marker40,"Dicolnox Ltda.",4.665378,-74.059103,'
Colombia
',"/thermalloys/site/en/thermalloys-worldwide/south-america/colombia/dicolnox-ltda.html",""],[89,marker40,"Sandvik Argentine S.A.",-23.442503,-58.443832,'
Paraguay
',"/thermalloys/site/en/thermalloys-worldwide/south-america/paraguay/sandvik-argentine-sa.html",""]]; addBusinesses1(); } } function setBounds1(bounds) { map1.setZoom(map1.getBoundsZoomLevel(bounds)); map1.setCenter(bounds.getCenter()); } function geocodeBusinesses1() { if (cntGeocoded1 < geocodes1.length) { geocoder1.getLocations(geocodes1[cntGeocoded1][7], addressResolved1); } } function addressResolved1(response) { var delay = 0; if (response.Status.code == 620) { delay = 500; } else { if (response.Status.code == 200) { var address = response.Placemark[0]; geocodes1[cntGeocoded1][3] = address.Point.coordinates[1]; geocodes1[cntGeocoded1][4] = address.Point.coordinates[0]; addBusiness1(geocodes1[cntGeocoded1]); } // Move onto the next address; this skips bad addresses, too. cntGeocoded1 += 1; } window.setTimeout(geocodeBusinesses1, delay); } function addBusinesses1() { for (var i=0; i < businesses1.length; i++) { addBusiness1(businesses1[i]); } } function addBusiness1(business) { var point = new GLatLng(business[3], business[4]); var markerOptions = { icon:business[1], draggable: false, "title":business[2] }; var marker = new GMarker(point, markerOptions); var form = ''; var info = business[5]; info = '