var isIE = false;
if (navigator.appName.indexOf("Microsoft")!=-1) {
  isIE = true;
}

var footerOpacity = 1;
var footerObj = null;
var footerDisplayed = false;

function setFooterObj(obj)
{
  footerObj = obj;  
  setFooterOpacity( 0 );
}

function setUpFooter()
{
  footerDisplayed = false;
}

function footerVisible()
{
  return footerDisplayed; 
}

function noteThatFooterIsNotVisible()
{
  footerDisplayed = false; 
}

function setFooterOpacity(percent)
{
  if (isIE == true)
  {
    footerObj.style.filter = "alpha(opacity=" + Math.round(percent * 100) + ")";
  }
  else
  {
    footerObj.style.opacity = percent;
  }

  footerOpacity = percent;
}

function fadeInFooter(timeout)
{
  footerDisplayed = true;
 
  footerOpacity = footerOpacity + 0.05;
 
  if (footerOpacity > 1)
  {
    footerOpacity = 1; 
  }
 
  setFooterOpacity(footerOpacity);
 
  if (footerOpacity != 1)
  {
    setTimeout(function() {fadeInFooter(timeout);}, timeout);
  }
}
