function markProjectThumbnail(pSrc) {
    $('img.project_miniature').css('border', 'none');
    $('img.project_miniature').css('width', '28px');
    $('img.project_miniature').css('height', '23px');
    
    $('#' + pSrc).css('border', '#04c2b5 1px solid');
    $('#' + pSrc).css('width', '26px');
    $('#' + pSrc).css('height', '21px');
}


function showMiniature(pIndex) {
	var len = tMiniatures.length;
	len--;

	$('#project_slideshow img').css('display', 'none');
	$('#slideshow_' + pIndex).css('display', 'block');
		
	act = pIndex;
	markProjectThumbnail('project_miniature_' + act);
		
	if (el2 != null) {
		el1 = el2;
		el2 = pIndex;
	} else {
		el2 = pIndex;
	}

	$('#project_slideshow').innerfade({ speed: 'slow', timeout: 500, type: 'pair', containerheight: '490px', item_first: el1, item_second: el2 });
}






function arrowOver(pSrc, pType) {
  if (pType == 'up') {
    pSrc.style.background = 'url(\'img/arrows/gray/arrow_up_green.gif\') center top no-repeat';
  } else if (pType == 'down') {
    pSrc.style.background = 'url(\'img/arrows/gray/arrow_down_green.gif\') center bottom no-repeat';
  } else if (pType == 'left') {
    pSrc.src = 'img/arrows/gray/arrow_left_green.gif';
  } else if (pType == 'right') {
    pSrc.src = 'img/arrows/gray/arrow_right_green.gif';
  }

  pSrc.style.cursor = 'pointer';
}


function arrowOut(pSrc, pType) {
  if (pType == 'up') {
    pSrc.style.background = 'url(\'img/arrows/gray/arrow_up.gif\') center top no-repeat';
  } else if (pType == 'down') {
    pSrc.style.background = 'url(\'img/arrows/gray/arrow_down.gif\') center bottom no-repeat';
  } else if (pType == 'left') {
    pSrc.src = 'img/arrows/gray/arrow_left.gif';
  } else if (pType == 'right') {
    pSrc.src = 'img/arrows/gray/arrow_right.gif';
  }

  pSrc.style.cursor = 'default';
}


function showLangButton(pSrc) {
  if (pSrc == 'lng_pl') {
    $('#lng_pl').attr('src', 'img/lang_pl_pl.gif');
    $('#lng_en').attr('src', 'img/lang_pl_en.gif');
    $('#lng_nl').attr('src', 'img/lang_pl_nl.gif');
  } else if (pSrc == 'lng_en') {
    $('#lng_pl').attr('src', 'img/lang_en_pl.gif');
    $('#lng_en').attr('src', 'img/lang_en_en.gif');
    $('#lng_nl').attr('src', 'img/lang_en_nl.gif');
  } else if (pSrc == 'lng_nl') {
    $('#lng_pl').attr('src', 'img/lang_nl_pl.gif');
    $('#lng_en').attr('src', 'img/lang_nl_en.gif');
    $('#lng_nl').attr('src', 'img/lang_nl_nl.gif');
  }
}


function activateScroll() {
	$(function()
		{
			$('#pane1').jScrollPane({showArrows:true, scrollbarWidth: 17});
		});
}


$(document).ready(function($) {
	//$('a[rel*=facebox]').facebox()
})


function showPartners(pId) {
	$('#partners_1').hide();
	$('#partners_2').hide();
	$('#partners_3').hide();
	$('#partners_4').hide();
	$('#partners_5').hide();
	$('#partners_6').hide();
	$('#partners_7').hide();
	$('#partners_8').hide();
	
	$('#partners_' + pId).show();
}