//	CCClm.js  -  scripts for Lake Mead Drought
//	includes CCCGlobal.js and lmCache()

//	CCCGlobal.js  -  scripts for all pages (makeNewWindow, goBack, twoClicks)
//	function makeNewWindow()
var newWindow = null;                           // initialize newWindow variable
function makeNewWindow(loc,name,size) {
//      Since we have varying sizes and shapes of windows, we need to
//      close it first, if it exists, so newWindow will open correctly.
  if (newWindow && !newWindow.closed)           // check for an open window
     { newWindow.close(); }                     // and close it if it exists
  newWindow = window.open(loc,name,size);       // then create the newWindow
    return false;                               // override the href #, and
    newWindow.focus();                          // be certain it is on top
}

//	function goBack()
function goBack() { window.history.back(); }

//	function twoClicks() - opens explanatory window for goBack()
var tcWindow = null;
function twoClicks() {
  if (tcWindow && !tcWindow.closed)
     { tcWindow.close(); }
  tcWindow = window.open('/TwoClicks.php','tcWindow','width=535,height=176'); 
    tcWindow.focus();
}
//	Lake Mead Drought
function lmCache() {
var lmPix = new Array() ;
  lmPix[0] = new Image(110,34) ;
  lmPix[0].src = "/Drought/images/MWG_b.jpg" ;
  lmPix[1] = new Image(930,465) ;
  lmPix[1].src = "/Drought/images/MeadGraph_lg.jpg" ;
  lmPix[2] = new Image(1000,458) ;
  lmPix[2].src = "/Drought/images/Intake.jpg" ;
  lmPix[3] = new Image(1000,518) ;
  lmPix[3].src = "/Drought/images/DesertPrincess.jpg" ;
  lmPix[4] = new Image(1000,675) ;
  lmPix[4].src = "/Drought/images/LakeMead.jpg" ;
  lmPix[5] = new Image(642,242) ;
  lmPix[5].src = "/Drought/images/mead_landsat00_03.jpg" ;
  lmPix[6] = new Image(930,641) ;
  lmPix[6].src = "/Drought/images/mead_l7_00.jpg" ;
  lmPix[7] = new Image(930,641) ;
  lmPix[7].src = "/Drought/images/mead_l7_04.jpg" ;
}

