/*
	_library classes:
	$Revision: 1.1 $
*/

function TheOpener(theUrl,WinName,width,height,scrollbar,resize,msgNoPopUp,goTo) {
//	theUrl 		= The page
//	width		= Width of the window
//	height		= Height of the windows
//	scroll		= Do You want the Scroll??? ][ Value = yes|no
//	resize		= Do You want to resize Window??? ][ Value = yes|no
//	msgNoPopUp	= set a message if popUp is not opened (aka blocked by a PopUp blocker)
//	goTo		= set a page where to go if popUp is not opened
//
// brought to you by []==ThoRŪ
//
	var x = screen.availWidth
	var y = screen.availHeight
	var spaceSx = (x - width)/2
	//var spaceUp = 0										// To Point PopUp top
	var spaceUp = (y - height)/2							// To point PopUp in the center

	winparams	= ""										// Start Params for Window
	winparams	= winparams + "scrollbars=" 	+ scrollbar	// Scroll
	winparams 	= winparams + ",resizable=" 	+ resize	// Resizable
	winparams 	= winparams + ",left=" 			+ spaceSx	// Space From Left
	winparams 	= winparams + ",top=" 			+ spaceUp	// Space From Top
	winparams 	= winparams + ",width=" 		+ width		// Windowz Width
	winparams 	= winparams + ",height=" 		+ height	// Windowz Height
	winparams 	= winparams + ",directory=no"				// The Tool Bar Menu
	winparams 	= winparams + ",status=no"					//
	winparams 	= winparams + ",location=no"				//
	winparams 	= winparams + ",toolbar=no"					// -------------------
	// Open window
	var ThoR	= window.open(theUrl,WinName,winparams);
	if (ThoR==null || typeof(ThoR)=="undefined")	{
		if (msgNoPopUp != "")	{
			alert(msgNoPopUp);
		}
		if (goTo != "")	{
			location.href	= goTo;
		}
	} else {
		// Active window
		ThoR.focus();
	}
}
function fullScreen(theUrl,WinName) {
	winparams	= ""										// Start Params for Window
	winparams	= winparams + "fullscreen=yes "				//	fullscreen
	var ThoR	= window.open(theUrl,WinName,winparams);
}
