//new browser test
agent = navigator.userAgent;
browserVer = (agent.indexOf("Mozilla/3") == -1 &&
		agent.indexOf("Mozilla/4") == -1 &&
		agent.indexOf("Mozilla/5") == -1) ? 0 : 1;

// - - - - - - - - - - - - - - - 

if (browserVer == 1) {

        gClick=" "

	    photo_1 = new Image(72,52);
		photo_1.src = "_img/listening/1-art-in-context-th.jpg";
		photo_1_mo = new Image(72,52);
		photo_1_mo.src = "_img/listening/1-art-in-context-th.mo.jpg";

	    photo_2 = new Image(72,52);
		photo_2.src = "_img/listening/2-materials-th.jpg";
		photo_2_mo = new Image(72,52);
		photo_2_mo.src = "_img/listening/2-materials-th.mo.jpg";

	    photo_3 = new Image(72,52);
		photo_3.src = "_img/listening/3-softscape-th.jpg";
		photo_3_mo = new Image(72,52);
		photo_3_mo.src = "_img/listening/3-softscape-th.mo.jpg";

	    photo_4 = new Image(72,52);
		photo_4.src = "_img/listening/4-furniture-det-th.jpg";
		photo_4_mo = new Image(72,52);
		photo_4_mo.src = "_img/listening/4-furniture-det-th.mo.jpg";

	    photo_5 = new Image(72,52);
		photo_5.src = "_img/listening/5-villa-materials-th.jpg";
		photo_5_mo = new Image(72,52);
		photo_5_mo.src = "_img/listening/5-villa-materials-th.mo.jpg";

}

// - - - - - - - - - - - - - - - 

function hiLite(imgDocID,imgObjName) {
// manages mouseOver animations
//   imgDocID - the name or number of the document image to be replaced
//   imgObjName - the name of the image object to be swapped in

	if (browserVer == 1) {
		if(imgDocID!=gClick)
                	document.images[imgDocID].src = eval(imgObjName + ".src");
	}
}

function setGlobal (imgDocID){
	if (gClick!=" "){
        document.images[gClick].src = eval(gClick + ".src");
    }
    gClick=imgDocID;
    document.images[gClick].src = eval(gClick + "_mo.src");

}



function WM_imageSwap(daImage, daSrc){
  var objStr,obj;
  /*
    WM_imageSwap()
    Changes the source of an image.

    Source: Webmonkey Code Library
    (http://www.hotwired.com/webmonkey/javascript/code_library/)

    Author: Shvatz
    Author Email: shvatz@wired.com

    Usage: WM_imageSwap(originalImage, 'newSourceUrl');

    Requires: WM_preloadImages() (optional, but recommended)
    Thanks to Ken Sundermeyer (ksundermeyer@macromedia.com) for his help
    with variables in ie3 for the mac. 
    */

  // Check to make sure that images are supported in the DOM.
  if(document.images){
    // Check to see whether you are using a name, number, or object
    if (typeof(daImage) == 'string') {
      // This whole objStr nonesense is here solely to gain compatability
      // with ie3 for the mac.
      objStr = 'document.' + daImage;
      obj = eval(objStr);
      obj.src = daSrc;
    } else if ((typeof(daImage) == 'object') && daImage && daImage.src) {
      daImage.src = daSrc;
    }
  }
}
