﻿
window._uds_msw_donotrepair = true;

function bootComplete(searchControl)
{
    // set mode of active and idle maps to satellite
    searchControl.idleGmap.setMapType(G_SATELLITE_MAP);
    searchControl.gmap.setMapType(G_SATELLITE_MAP);
}
var fooObject = new Foo(G_HYBRID_MAP);
function LoadMapSearchControl() {

  var options = {
        zoomControl : GSmapSearchControl.ZOOM_CONTROL_ENABLE_ALL,
        title : "Stapleford Baptist Church, Albert Street, Stapleford, Nottingham, NG9 8DB",
        url : "http://www.staplefordbaptist.org",
        selectedIcon : G_DEFAULT_ICON,
        unselectedIcon : G_DEFAULT_ICON,
        idleMapZoom : GSmapSearchControl.ACTIVE_MAP_ZOOM+2,
        activeMapZoom : GSmapSearchControl.ACTIVE_MAP_ZOOM+2,
        mapTypeControl : GSmapSearchControl.MAP_TYPE_ENABLE_ALL,
        drivingDirections : GSmapSearchControl.DRIVING_DIRECTIONS_FROM_USER,
        linkTarget : GSearch.LINK_TARGET_SELF,
        onBootComplete : GSmapsc_methodCallback(fooObject, Foo.prototype.loadCallback)
        }

 new GSmapSearchControl(
        document.getElementById("mapsearch"),"stapleford baptist church, stapleford, nottingham, uk",
        options
        );   
}
function Foo(type) 
{
    this.type = type;
}
Foo.prototype.loadCallback = function(searchControl) {
searchControl.idleGmap.setMapType(this.type);
searchControl.gmap.setMapType(this.type);
}

// arrange for this function to be called during body.onload
// event processing
GSearch.setOnLoadCallback(LoadMapSearchControl);
 

