function doMagicLine(menu) {
	menu.each(function() {
		var line = $('> .magic_line',menu);
		var active = $('> li.active',menu);
		
		var animCount = 0;
		
		if(line.length===0 && active.length>0){
			menu.append('<li class="magic_line"></li>');
			line = $('> .magic_line',menu);
			
			var origLeft = active.position().left;
			var origWidth = active.width();
			
			
			line.width(origWidth);
			line.css({
				'left' : origLeft+'px'
			});
			
			var doMenuHover = function(e) {
				var $this = $(this);
				
				var left = $this.position().left;
				var width = $this.outerWidth();
				line.stop(true).animate({
					'width' : width+'px',
					'left' : left+'px'
				}, 400, 'linear');
			};
			
			var doMenuHoverOff = function(e) {
				var $this = $(this);
	
				var left = active.position().left;
				var width = active.outerWidth();
				line.stop(true).animate({
					'width' : width+'px',
					'left' : left+'px'
				}, 400, 'linear');
			};
			
			$('> li:not(.magic_line, .active)', menu).hover(doMenuHover,doMenuHoverOff);
		}
	});
}
