var Interval = null;
var maxRange = 60;
var speed = 5;

var currentHeight = 15;

function activateSlideIn(){
      Interval = window.setInterval('slideIn()',50);
}


function slideIn(){
   try{
      var menuItem = document.getElementById('active_Menuitem');

      if(currentHeight  >= maxRange){
         window.clearInterval(Interval);
      }
      else{
           currentHeight = currentHeight + speed;
           menuItem.style.height= currentHeight + 'px';
      }
   }catch(e){}  
  
}

/**
 * Fade in the logo when the mouse enters and fade it out on the mouse leave event.
 * Both events will bind to the anchor with id=logo when document is ready.
 *
 * @author: Steffen Stollfuß (s.stollfuss@infos.de)
 * @copyright (c) 2009 infoServe GmbH
 */
$(document).ready( function() {
    var objLogoImage = $("img[id=logo]");
    var objLogoLink = $("a[id=logo]");
    var bLogoSem = false;

    objLogoLink.bind("mouseenter", function(e){
        if( !bLogoSem ) {
            bLogoSem = true;
            objLogoImage.fadeIn('slow', function(){bLogoSem = false;});
        }
    });
    
    objLogoLink.bind("mouseleave", function(e){
        if( !bLogoSem ) {
            sem = true;
            objLogoImage.fadeOut('slow', function(){bLogoSem = false;});
        }
    });
});