google.load("jquery", "1.3.2");

/* extends jQuery */
function extendJQuery()
{
	$.fn.findPos = function()
	{
		obj = $(this).get(0);
		var curleft = obj.offsetLeft || 0;
		var curtop = obj.offsetTop || 0;
		while (obj = obj.offsetParent) {
			curleft += obj.offsetLeft
			curtop += obj.offsetTop
		}
		return {x:curleft, y:curtop};
	}
}

function setup_main()
{
	$('#header li')
		.mouseenter(function (){
			$(this).find('img').show();
		})
		.mouseleave(function (){
			$(this).find('img').hide();
		});
}

function onResize()
{
}

function onResizeDelayed()
{
}

/* init */
function initialize()
{
	extendJQuery();
	
	setup_main();
	
	$(window).resize(onResize);
	resizeTimer = null;
	$(window).bind('resize', function() {
		clearTimeout(resizeTimer);
		resizeTimer = setTimeout(onResizeDelayed, 500);
	});
}

google.setOnLoadCallback(initialize);

