var utilsIncluded = false;
var lastZ = 1;
var _hJS_szRootPath = "";

function _hJS_includeScript( strName )
{
	var head = document.getElementsByTagName('head').item(0);
	var script = document.createElement('script');
	script.setAttribute('language', 'javascript');
	script.setAttribute('type', 'text/javascript');
	script.setAttribute('src', _hJS_szRootPath + "hJSlib/src/" + strName);
    	head.appendChild(script);
}

function _hJS_includeCSS( strName )
{
	var strCSS = "hJSlib/css/" + strName;
	if(document.createStyleSheet) 
	{
		document.createStyleSheet(strCSS);
	}
	else 
	{
		var head = document.getElementsByTagName('head').item(0);
		var script = document.createElement('link');
		script.setAttribute('rel', 'stylesheet');
		script.setAttribute('type', 'text/css');
		script.setAttribute('href', strCSS);
	    	head.appendChild(script);
	}
}


function _hJS_includeUtilities()
{
	if ( utilsIncluded == false )
	{
		_hJS_includeScript("utils.js");
		utilsInclude = true;
	}
}

function hJS_SetupDialogs()
{
}


function hJS_SetRootPath( strPath )
{
	_hJS_szRootPath = strPath;
}

function hJS_SetupMenus()
{
	_hJS_includeUtilities();
	_hJS_includeCSS("menus.css");
	_hJS_includeScript("menus.js");

}


function hJS_SetupAJAX()
{
	_hJS_includeScript("ajax.js");
}


function hJS_SetupAll()
{
	hJS_SetupMenus();
	hJS_SetupDialogs();
	hJS_SetupAJAX();
}
