// $_meef is main object containing javascript logic
var _meef = {};
// very common stuff declared here only
//
_meef.debug = function(s)	{
	if (typeof console != "undefined" && typeof console.debug != "undefined") {
			console.log(s);
	} else {
		alert(s);
	}
};
_meef.scrollTo = function(el)	{
	// use jQuery.scrollTo for scrolling above element
	if (!$.scrollTo)	return;
	$.scrollTo('#' + el, {duration: 300, offset: {top: -30} });
}
_meef.fixPng = function(el)	{
	// fix png without autoPNG (e.g. on logo before loading the complete page)
	var msie6 = false;
	if ($.browser.msie && parseInt($.browser.version) == 6) msie6 = true;
	if (!msie6)	return;

	$(el).each(function(){
		$(this).removeClass('autoPng').ifixpng();
	});
}
_meef.popup = function(self, width, height)	{
	  var url = $(self).attr('href');
	  var newwindow = window.open(url,'popup','width=' + width + ',height=' + height + ',scrollbars=yes,top=40');
	  if (newwindow.focus)	newwindow.focus();
	  return false;
}
