var clickOK = 1;
var d=document;

function preloader() {if(d.images){
	if(!d.loaderarray) { d.loaderarray=new Array(); }
	var i,j=d.loaderarray.length,a=preloader.arguments;
	for(i=1; i<a.length; i++) { if (a[i].indexOf("#")!=0) { d.loaderarray[j]=new Image;
	d.loaderarray[j++].src= a[0]+a[i]; } }
}}

function preload(intro) {
//	preloader('nav/','nav_on.jpg','nav_off.jpg');
	preloader('img/p','+.gif','-.gif','=.gif');
}

prev_width  = 0;
prev_height = 0;
verschil_width = 0;
verschil_height= 0;
plaatje_groot= new Image;
plaatje_doel = new Image;
plaatje_nu= '-';
ani_actie = '';
var ani_timer = new Array();
function groot_resize(richting) {
	if (plaatje_org.width < 50 ) { return }
	if ( richting == '+' && plaatje_groot.width == 0 ) {
	 	ani_timer[0] = setTimeout("groot_resize('+')",200); return;
	}
	else if (ani_actie == '' ) {
		if ( richting == '+' && plaatje_nu == '-') {
			prev_width  = plaatje_org.width;
			prev_height = plaatje_org.height;
			verschil_width = plaatje_org.width -plaatje_groot.width;
			verschil_height= plaatje_org.height-plaatje_groot.height;
			plaatje_doel   = plaatje_groot;
			plaatje_nu=richting;
			groot_resize2(richting);
		} else if ( richting == '-' && plaatje_nu == '+') {
			prev_width  = plaatje_groot.width;
			prev_height = plaatje_groot.height;
			verschil_width = plaatje_groot.width -plaatje_org.width;
			verschil_height= plaatje_groot.height-plaatje_org.height;
			plaatje_doel   = plaatje_org;
			plaatje_nu=richting;
			groot_resize2(richting);
		}
	} else if (richting != plaatje_nu ) {
	 	ani_timer[0] = setTimeout("groot_resize('"+richting+"')",200);
	}
}
ani_stap = 50;
function groot_resize2(richting) {
	ani_actie = 'ani';
//	parent.document.title= ani_actie+' '+parent.document.title;
	ani_timer[01] = setTimeout("groot_img.src=plaatje_groot.src",ani_stap*0.99);
	ani_timer[02] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.1)+";groot_img.height="+eval(prev_height-verschil_height*.1),ani_stap*1);
 	ani_timer[03] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.2)+";groot_img.height="+eval(prev_height-verschil_height*.2),ani_stap*2);
 	ani_timer[04] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.3)+";groot_img.height="+eval(prev_height-verschil_height*.3),ani_stap*3);
 	ani_timer[05] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.4)+";groot_img.height="+eval(prev_height-verschil_height*.4),ani_stap*4);
 	ani_timer[06] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.5)+";groot_img.height="+eval(prev_height-verschil_height*.5),ani_stap*5);
 	ani_timer[07] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.6)+";groot_img.height="+eval(prev_height-verschil_height*.6),ani_stap*6);
 	ani_timer[08] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.7)+";groot_img.height="+eval(prev_height-verschil_height*.7),ani_stap*7);
 	ani_timer[09] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.8)+";groot_img.height="+eval(prev_height-verschil_height*.8),ani_stap*8);
 	ani_timer[10] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*.9)+";groot_img.height="+eval(prev_height-verschil_height*.9),ani_stap*9);
 	ani_timer[11] = setTimeout("groot_img.width="+eval(prev_width-verschil_width*1 )+";groot_img.height="+eval(prev_height-verschil_height* 1),ani_stap*10);
 	ani_timer[12] = setTimeout("ani_actie='';groot_img.src='"+plaatje_doel.src+"'",ani_stap*10);
}
//window.setInterval("document.title=ani_actie+' '+plaatje_nu+' '+plaatje_org.width+' '+plaatje_org.width",250);

function lineflip(tr_id,groep,actie) {
	if (      actie == 1 ) { tr_id.style.backgroundColor='#ffcc00' }
	else if ( groep == 1 ) { tr_id.style.backgroundColor='#eeeeee' }
	else                   { tr_id.style.backgroundColor='#ffffff' }
}

