// JavaScript Document
  
  var scrollTimer;
  var scrollInterval = 60;
  var scrollDiv;
  var scrollPaused = false;
  var scrollStopped = false;

  function startScroll()  {
	  if ( BrowserDetect.browser != 'Explorer' || BrowserDetect.version == 8) 
	    scrollTimer = setInterval( scrollForecast, scrollInterval);
      else
		document.getElementById(scrollDiv).style.height = 222;
  }
  
  function pauseScroll()  {
    scrollPaused = true;
  }
  
  function unpauseScroll()  {
    scrollPaused = false;
  }
  
  function toggleScroll()  {
    scrollStopped = !scrollStopped;
  }
  
  function scrollForecast()  {
    if (!(scrollPaused || scrollStopped))  {
      var top = parseInt(getStyle(document.getElementById(scrollDiv), 'top'));
      var height = getStyle(document.getElementById(scrollDiv), 'height');

      if (height == 'auto') height = document.getElementById(scrollDiv).offsetHeight;
      height = parseInt(height);

      top -= 1;
      if (top + height < -10) top = height-80;
      document.getElementById(scrollDiv).style.top = top.toString() + 'px';
	}
  }
  
  function showDate()  {
    changeText('forecastTitle', CurrentDate() + ' (Central Time)');
  }

  function showForecast()  {
    scrollDiv = 'Central' + DateID(0);
    showDiv(scrollDiv);
  }



