/////////////////////////////////////////////////////////////////////////////
// Function : NavNode (constructor)
// Comments :
/////////////////////////////////////////////////////////////////////////////
function NavNode(id, label, href, parent)
{
	this.m_parent = null;
	this.m_level = 0;

	if (parent)
	{
		this.m_parent = parent;
		this.m_level = parent.m_level+1;
	}

	this.m_id = id;

	// assume that m_label will most often be used directly as HTML
	this.m_rawlabel = label;

	label = label.replace(/&/g, '&amp;');
	label = label.replace(/</g, '&lt;');
	label = label.replace(/>/g, '&gt;');
	label = label.replace(/"/g, '&quot;');

	this.m_label = label;

	this.m_href = href;
	this.m_subNodes = new Array();

	var argValues = NavNode.arguments;
	var argCount = NavNode.arguments.length;

	for (i = 4 ; i < argCount ; i++)
	{
		var eqPos = argValues[i].indexOf("==");
		var attrName = argValues[i].substring(0,eqPos);
		var attrValue = argValues[i].substring(eqPos+2);

		eval("this.cp_" + attrName + " = '" + attrValue + "';");
	}

	NavNode.prototype.addNode = addNode;
	NavNode.prototype.isSelected = isSelected;
}

/////////////////////////////////////////////////////////////////////////////
// Function : addNode
// Comments :
/////////////////////////////////////////////////////////////////////////////
function addNode(id, label, href)
{
	var newIndex = this.m_subNodes.length;
	var newNode = new NavNode(id, label, href, this);

	var argValues = addNode.arguments;
	var argCount = addNode.arguments.length;

	for (i = 3 ; i < argCount ; i++)
	{
		var eqPos = argValues[i].indexOf("==");
		var attrName = argValues[i].substring(0,eqPos);
		var attrValue = argValues[i].substring(eqPos+2);

		eval("newNode.cp_" + attrName + " = '" + attrValue + "';");
	}

	this.m_subNodes[newIndex] = newNode;
	return newNode;
}

/////////////////////////////////////////////////////////////////////////////
// Function : isSelected
// Comments :
/////////////////////////////////////////////////////////////////////////////
function isSelected()
{
    var pos = window.location.href.lastIndexOf("/");
    var docname = window.location.href.substring(pos+1, window.location.href.length);

    pos = this.m_href.lastIndexOf("/");
    var myname = this.m_href.substring(pos+1, this.m_href.length);

    if (docname == myname)
		return true;
	else
		return false;
}

/////////////////////////////////////////////////////////////////////////////
// Function : customSectionPropertyExists
// Comments :
/////////////////////////////////////////////////////////////////////////////
function customSectionPropertyExists(csp)
{
	return (typeof csp != _U && csp != null);
}

/////////////////////////////////////////////////////////////////////////////
// Function : getCustomSectionProperty
// Comments :
/////////////////////////////////////////////////////////////////////////////
function getCustomSectionProperty(csp)
{
	if (customSectionPropertyExists(csp))
	{
		return csp;
	}
	else
	{
		return "";
	}
}

/////////////////////////////////////////////////////////////////////////////

var g_navNode_Root = new NavNode('3283','ACTRAV',ssUrlPrefix + 'index.htm',null,'NavigationRootLevel==1','SectionLabel_en==Bureau for Workers\\x27 Activities \x28ACTRAV\x29','SectionLabel_es==Oficina de Actividades para los Trabajadores \x28ACTRAV\x29','SectionLabel_fr==Bureau des Activit\xe9s pour les Travailleurs \x28ACTRAV\x29','SiteLabel_en==ACTRAV','SiteLabel_es==ACTRAV','SiteLabel_fr==ACTRAV','SiteLanguages==en,es,fr','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_0=g_navNode_Root.addNode('3284','About us',ssUrlPrefix + 'about/index.htm','SectionLabel_en==About ACTRAV','SectionLabel_es==Qui\xe9nes somos','SectionLabel_fr==\xc0 propos de nous','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_2=g_navNode_Root.addNode('3286','Areas of work',ssUrlPrefix + 'areas/index.htm','SectionLabel_en==Areas of work','SectionLabel_es==Ambitos de trabajo','SectionLabel_fr==Domaines de travail','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_3=g_navNode_Root.addNode('3287','Regional activities',ssUrlPrefix + 'countries/index.htm','SectionLabel_en==Regional activities','SectionLabel_es==Pa\xedses abarcados','SectionLabel_fr==Pays couverts','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_4=g_navNode_Root.addNode('3288','What we do',ssUrlPrefix + 'what/index.htm','SectionLabel_en==What we do','SectionLabel_es==Actividades','SectionLabel_fr==Activit\xe9s','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_4_0=g_navNode_4.addNode('3289','Projects',ssUrlPrefix + 'what/projects/index.htm','SectionLabel_en==Projects','SectionLabel_es==Proyectos','SectionLabel_fr==Projets','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_4_1=g_navNode_4.addNode('3290','Events and meetings',ssUrlPrefix + 'what/events/index.htm','SectionLabel_en==Events and meetings','SectionLabel_es==Eventos y reuniones','SectionLabel_fr==\xc9v\xe9nements et reunions','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_4_2=g_navNode_4.addNode('3291','Publications',ssUrlPrefix + 'what/pubs/index.htm','SectionLabel_en==Publications','SectionLabel_es==Publicaciones','SectionLabel_fr==Publications','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5=g_navNode_Root.addNode('3293','Information resources',ssUrlPrefix + 'info/index.htm','SectionLabel_en==Information resources','SectionLabel_es==Recursos de Informaci\xf3n','SectionLabel_fr==Ressources d\u2019information','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_0=g_navNode_5.addNode('3296','Factsheets',ssUrlPrefix + 'info/fs/index.htm','SectionLabel_en==Factsheets','SectionLabel_es==Hojas de datos','SectionLabel_fr==Fiches d\\x27information','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_1=g_navNode_5.addNode('3295','Press releases',ssUrlPrefix + 'info/pr/index.htm','SectionLabel_en==Press releases','SectionLabel_es==Comunicados de prensa','SectionLabel_fr==Communiqu\xe9s de presse','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_2=g_navNode_5.addNode('3300','Audio',ssUrlPrefix + 'info/audio/index.htm','SectionLabel_en==Audio','SectionLabel_es==Audio','SectionLabel_fr==Audio','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_3=g_navNode_5.addNode('3298','Speeches',ssUrlPrefix + 'info/speeches/index.htm','SectionLabel_en==Speeches','SectionLabel_es==Discursos','SectionLabel_fr==Discours','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_4=g_navNode_5.addNode('3297','Newsletters',ssUrlPrefix + 'info/nl/index.htm','SectionLabel_en==Newsletters','SectionLabel_es==Boletins','SectionLabel_fr==Bulletins','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_5=g_navNode_5.addNode('3299','Video',ssUrlPrefix + 'info/video/index.htm','SectionLabel_en==Videos','SectionLabel_es==V\xeddeos','SectionLabel_fr==Vid\xe9os','secondaryUrlVariableField==pl_replaceable_content');
g_navNode_5_6=g_navNode_5.addNode('3305','Links',ssUrlPrefix + 'info/links/index.htm','SectionLabel_en==Links','SectionLabel_es==Enlaces \xfatiles','SectionLabel_fr==Liens utiles','secondaryUrlVariableField==pl_replaceable_content');

