
                function initMap() 
                {
                    //return;
//                     alert("initMap");

                    if (google.maps.BrowserIsCompatible()) {
                        map = new google.maps.Map2(document.getElementById("map"));
                        var kh = new GKeyboardHandler(map);

                        map.setCenter( new google.maps.LatLng( defaultMapCenter.lat, defaultMapCenter.lon), defaultMapCenter.zoom );

                        // bounds for the campus map overlay
                        var boundaries = new GLatLngBounds(
                                new GLatLng( campusOverlay.south , campusOverlay.west  ), // SW
                                new GLatLng( campusOverlay.north , campusOverlay.east ) // NE
                                            );
                        campusMap = new GGroundOverlay(campusOverlay.imageURL, boundaries);
                        map.addOverlay(campusMap);

//                         map.addControl(new GLargeMapControl());
                        map.addControl(new GSmallMapControl());
                        map.addControl(new GMapTypeControl());
//                         updateBoundsFields();
                        
                    }
                }

            function initSearchBox()
            {
                var autoCompleteList = new Array();
                for (var i=0; i<allPlaces.length; i++)
                {
                    autoCompleteList.push( 
                            ( ( allPlaces[i].code && allPlaces[i].code != "" ) ? allPlaces[i].code.toUpperCase() + " - "  : "" )
                        +  allPlaces[i].name 
                    );
                }

                // add aliases to the search box also ... 
                for (var buildingIndex=0; buildingIndex<buildingAliases.length; buildingIndex++)
                {
                    for (var aliasIndex=0; aliasIndex< buildingAliases[buildingIndex].aliases.length; aliasIndex++)
                    {
                        autoCompleteList.push(
                            buildingAliases[buildingIndex].code.toUpperCase() 
                            + " - " 
                            + buildingAliases[buildingIndex].aliases[aliasIndex]
                        );
                    }
                }
                actb( document.getElementById("searchbox"), autoCompleteList );
                for (var type in allPlaceTypes)
                {
                    document.getElementById(type + "check").checked = false;
                }
            }


            // load and parse the XML event feed into an array of CampusEvent objects - CampusEventList
            function initEventFeed() {
                //return;
                
                // var feed = new google.feeds.Feed("http://www.google.com/calendar/feeds/asu.edu_q065bkoducouhbr42c83548dgk%40group.calendar.google.com/public/full?orderby=starttime&sortorder=ascending&futureevents=true&max-results=500");
                loadFeed( eventFeeds[defaultFeed] );

            }

            function createTimeline()
            {
                eventSource = new Timeline.DefaultEventSource(0); 
                var bandInfos = [ 
                    Timeline.createBandInfo( { 
                            width:          "75%", 
                            timeZone: -6, 
                            eventSource:    eventSource, 
                            intervalUnit:   Timeline.DateTime.DAY, 
                            intervalPixels: 160 
                        }),
                    Timeline.createBandInfo( {
                            width:          "25%", 
                            timeZone: -6, 
                            eventSource:    eventSource, 
                            intervalUnit:   Timeline.DateTime.WEEK, 
                            intervalPixels: 160 ,
                            showEventText: false
                        })
                ];

                // sync bands 
                bandInfos[0].highlight = true; 
                bandInfos[1].syncWith = 0; 
                bandInfos[1].highlight = true; 

                tl = Timeline.create(document.getElementById("mytimeline"), bandInfos, Timeline.HORIZONTAL); 
                // eventSource is loaded later, with events from CampusEventList ( see initEventFeed )
//                     eventSource._fire("onAddMany",[]);
            }

            // not using this one ... TODO remove or update (?)
//                 function populateTimeline()
//                 {
//                     alert(" events = " + CampusEventList.length );
//                     for (var i=0; i< CampusEventList.length; i++)
//                     {
//                         CampusEventList[i].addMeToTimeline( eventSource );
//                         var evt = CampusEventList[i].toTimelineEvent();
//                         eventSource.add(evt);
//                     }
//                     eventSource._fire("onAddMany",[]);
//                 }
