var cw=null;

// fonction d'ouverture d'une petite fenetre
// url : fichier a afficher dans cette fenetre
// w,h : largeur,hauteur de cette fenetre
// xi,yi : coords de la fenetre : utiliser -1,-1 pour centrer la fenetre

function pop(url, w, h, xi, yi) {
  doPop(url, 'pop', w, h, xi, yi);
}

function doPop(url, str, w, h, xi, yi) {
	var opt="";
	var x=(xi==-1)?(screen.width-w)/2:xi;
	var y=(yi==-1)?(screen.height-h)/2:yi;
	opt='toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width='+w+',height='+h+',top='+y+',left='+x;
	cw=window.open(url, str, opt);
	cw.focus();
}

// exception pour page de l'arbo directe
function pop0(url, w, h, xi, yi) {
  doPop(url, 'pop3', w, h, xi, yi);
}

// pop 2e niveau
function pop2(url, w, h, xi, yi) {
  doPop(url, 'pop2', w, h, xi, yi);
}

// pop 3e niveau
function pop3(url, w, h, xi, yi) {
  doPop(url, 'pop3', w, h, xi, yi);
}
