 

/***********************************************
* Auto Maximize Window Script-  Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for this script and 100's more.
***********************************************/

top.window.moveTo(0,0);
if (document.all) 
  {
  top.window.resizeTo(screen.availWidth,screen.availHeight);
  }
  else if (document.layers||document.getElementById) 
  {
  if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth)
  {
   top.window.outerHeight = screen.availHeight;
   top.window.outerWidth = screen.availWidth;
   }
  }
//-->

var descrizionePanorama;
var descrizionePanorama_1

function Visible(obj)
{	
 obj=document.getElementById(obj);
 vis=obj.style.visibility;
  res="";
 if(vis=="visible") res="hidden";
 else
 res = "visible";  
 obj.style.visibility=res;
}

// finestra modale per le istruzioni
function istruzioni()
{	
window.open("modal.html","mappa","width=200,height=200,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ")
}

// chiude la finestra
function chiudi()
  {	
	window.close();	
  }

// funzione da hot spot

  
function openlink(url)
 {  
  var ivp =".ivp" 
  var titoloPanorama;
  var title = document.title //ottiene il valore del titolo per distinguere tra java e flash ed usare il comando giusto di apertura 
  
  var desc1 = 'Villa Clelia e\' un bellissimo casolare rustico situato in un colle tra ulivi e querce a 800 metri dal Coppo di Sirolo.<br>All\'aperto, troverai un ampio giardino molto curato in ogni suo particolare con un grande parcheggio.';
  
  var desc2 = 'Villa Clelia e\' il luogo ideale per ospitare cerimonie e festeggiare ricorrenze.<br>Nella sala ristorante, in quel giorno, si creera\' un\' affascinante e suggestiva atmosfera. ';
  
  var desc3 = 'Nella nostra bellissima piscina e\' possibile allestire ricchi buffet per rendere ancora piu\' speciale la tua cerimonia.';
  

  
  var ist = 'Istruzioni';	
  

  if(url=='istruzioni') {descrizionePanorama = ist; titoloPanorama='Istruzioni';}
  if(url=='panorama01') {descrizionePanorama = desc1; titoloPanorama='Villa Clelia';}
  if(url=='panorama02') {descrizionePanorama = desc2; titoloPanorama='Sala Cerimonie';}
  if(url=='panorama03') {descrizionePanorama = desc3; titoloPanorama='Piscina';}





 
  descrizionePanorama_1=descrizionePanorama
  if(title=='flash') document.PurePlayer.loadpano(''+url+''+ivp+'',false);
  if(title=='Virtualtour Villa Clelia') document.PurePlayer.execgui("loadpano(\""+url+''+ivp+"\",false)");
  
  document.getElementById("descrizione").innerHTML = descrizionePanorama;	
  document.getElementById("titolo").innerHTML = titoloPanorama;	  
}
// gruppo funzioni per nascondere  div ======================================================
 function toggleDiv(divid){
    if(document.getElementById(divid).style.display == 'none'){
	document.getElementById(divid).style.display = 'block';
	
    }else{
      document.getElementById(divid).style.display = 'none';	 
    }
  }
 // gruppo funzioni per rollover immagini   =======================================================
  function high(which2){
	theobject=which2
	highlighting=setInterval("highlightit(theobject)",40)
}
function low(which2){
	clearInterval(highlighting)
	if (which2.style.MozOpacity)
		which2.style.MozOpacity=0.3
	else if (which2.filters)
		which2.filters.alpha.opacity=20
}

function highlightit(cur2){
	if (cur2.style.MozOpacity<1)
		cur2.style.MozOpacity=parseFloat(cur2.style.MozOpacity)+0.1
	else if (cur2.filters&&cur2.filters.alpha.opacity<100)
		cur2.filters.alpha.opacity+=10
	else if (window.highlighting)
		clearInterval(highlighting)
}
// link in channel mode   =======================================================
function OpenFull(url) 
{
var ndoc = window.open(url,"full","channelmode=yes, statusbar=no")

{ 
ndoc;
setTimeout('sostituisci()',2000);
 }
}
function torna(){OpenFull('indexfull.htm')}
function torna1(){OpenFull('indexfulljava.htm')}
function sostituisci()
{document.getElementById("body").innerHTML= '<div align="center"><br><br>Torna al tour <a href="javascript:OpenFull(\'indexflash.htm\');">In Flash</a><br>Torna al tour <a href="javascript:OpenFull(\'indexjava.htm\');">In Java</a> </div>';
 }