if(typeof(screen)=="object"){w=screen.width;h=screen.height;}
function apriFlat(name,rows,srctop,srcmain,w,h,x,y,scroll)
{	html="<html><head><title>Andreoli Italian Jewellery</title></head><frameset onfocus=\"top.window.moveTo("+x+","+y+")\" rows=\""+rows+",*\"";
	html+=" framespacing=\"0\"><frame name=\"up\" src=\""+srctop+"\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" frameborder=\"0\">";
	html+="<frame name=\"main\" src=\""+srcmain+"\" marginwidth=\"0\" marginheight=\"0\" scrolling=\""+scroll+"\" frameborder=\"0\"></frameset></html>";
	flat=window.open("",name,"channelmode=0,fullscreen=1,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width="+w+",height="+h);
	flat.resizeTo(Math.ceil(w), Math.ceil(h));flat.moveTo(Math.ceil(x), Math.ceil(y));
	flat.document.open();flat.document.write(html);flat.document.close();flat.focus();	
}
var stato = "up"; var ofx=0; var ofy=0; var px=0; var py=0;
function sposta()
{	if(stato=="down"){ofx= event.x;ofy= event.y;stato="drag";} 																				
	else if( stato == "drag") 
	{ 	px=event.screenX-ofx-1;py=event.screenY-ofy-1; 																
		top.window.x=px;top.window.y=py;top.window.moveTo(px,py); 																
	} 
	else stato="up";
}
function riduci() 
{	top.window.moveTo(0,-4000); 		
	if ((top.opener)&&(!top.opener.closed)){top.opener.window.focus();} 									
	top.window.blur() 																		
}
function ripristina()
{	top.window.moveTo(0,0);	
} 							

