/*{{{ init... */

var ShowIncW = 100;
var ShowIncH = 140;

var ShowPicUrl;
var ShowPicText;
var ShowPicW;
var ShowPicH;

var Win = null;
/*}}}*/

/*{{{*/function Picture (o,w,h,alt)
{
	if ( !o || !o.href ) { return true; }

	var href = String ( o.href );

	ShowPicUrl = href;
	ShowPicText = alt;

	var ShowWinW = w+ShowIncW;
	var ShowWinH = h+ShowIncH;

	if ( Win && Win!=null /*&& w!=ShowPicW && h!=ShowPicH*/ ) { Win.close(); }

	ShowPicW = w;
	ShowPicH = h;

	var WW = screen.width-100;
	var HH = screen.height-100;
	if ( ShowWinW > WW ) { ShowWinW=WW; }
	if ( ShowWinH > HH ) { ShowWinH=HH; }
	var ShowWinX = Math.floor ( (screen.width-ShowWinW) / 2 )-40;
	var ShowWinY = Math.floor ( (screen.height-ShowWinH) / 2 )-30;

	var url = 'Images/Picture.htm';
	var id = '_PictureCopen';

	var props = "dependent=yes";
	props += ",location=no";
	props += ",statusbar=no,menubar=no";
	props += ",resizable=yes,scrollbars=no";
	props += ",width="+ShowWinW+",height="+ShowWinH;
	props += ",left="+ShowWinX+",top="+ShowWinY;

	Win = window.open(url, id, props);
	Win.focus();

	return false;
}/*}}}*/

