
/* Pagina de Inicio */
function inicio(objk, direccion){
    if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>3)){
        objk.style.behavior="url(#default#homepage)";
        objk.setHomePage(direccion);
    }
    else{
        alert("Su navegador no dispone de esta opcion.");
    }
}

/* Agregara favoritos */
function agregar(url, titulo) {
    if ((navigator.appName=="Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>=4)) {
        window.external.addFavorite(url, titulo);
    } else {
        if(navigator.appName == "Netscape") {
            alert (" Presiona Crtl+D para agregar esta web a tus Favoritos. ");
        }
    }
}

function sobre(elemento) {
  $(elemento).setStyle({backgroundColor: '#F1F1F1'});
}

function fuera(elemento, color) {
  $(elemento).setStyle({backgroundColor: color});
}

var album = { 
  startup: function() {
    new PeriodicalExecuter(album.cycle, 5) // change image every 5 seconds
  }, 
  cycle: function() {
    new Effect.Fade('img_animacion', { // the id of the <DIV> containing the photos 
      duration: 1, 
      fps: 50, 
      afterFinish: function() {
        new Ajax.Updater('img_animacion', 'http://www.dimater.com.ar/public/images', { // URL for next <IMG> tag
          asynchronous: true, 
          onSuccess: function() { 
            new Effect.Appear('img_animacion', {
              duration: 1,
              fps: 50,
              queue:'end'
            })
          } 
        }) 
      } 
    }) 
  } 
}
