var nOffset = 2;
var nWidth = (80 - 1);
var str = "";
var nCnt = 0;
var quote = "'";

function wndPopup (strPopupPage, pxWidth, pxHeight, bToolBar)
{
	window.open(strPopupPage, "window", 'screenX=0,screenY=0,toolbar=' + bToolBar + ',location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=' + pxWidth + ',height=' + pxHeight);
}

var navCategories = new Array	(
	'nav', 'Main Menu', '<a href="/">Home</a><br><br><a href="http://blog.spench.net/">Blog</a><br><br>Email me:<br><br><img src="/img/email.png" width="158" height="21">',
	'new', 'New Items', '<a href="/pix/dorkbot/"><img src="/pix/thumbs/dorkbot.jpg" width="50" height="50" border="0"><br>Dorkbot: Sydney</a><br><br><a href="/video/icinema/"><img src="/video/thumbs/tvis.jpg" width="50" height="50" border="0"><br>TVisionarium Mk II</a><br><br><a href="/thesis/undergrad/"><img src="/thesis/thumbs/commdet.jpg" width="50" height="50" border="0"><br>Real-time detection of TV ads</a>',
	'popular', 'Popular', 'My server often receives requests for:<br><br><a href="/pix/dual_monitors.html"><img src="/pix/thumbs/dual_monitor_setup_small.jpg" width="50" height="50" border="0"><br>Dual monitor Quake III</a><br><br><a href="/wifi/antennas.html"><img src="/wifi/thumbs/tripod_cantenna_small.jpg" width="50" height="50" border="0"><br>WiFi Cantennas</a><br><br><a href="/3421/cloth/"><img src="/3421/cloth/thumbs/cloth.jpg" width="50" height="50" border="0"><br>Verlet integration based cloth simulation</a>'
);

for (; nCnt < navCategories.length; nCnt += 3)
{
	document.write('<div class="section-area" style="LEFT: ' + nOffset + 'px">');
	document.write('<div id="section_'	+ navCategories[nCnt] + '" class="section"	onMouseOver="pageSections_Show(' + quote + navCategories[nCnt] + quote + ', this, 0);" onMouseOut="pageSections_HideCurrent();">' + navCategories[nCnt + 1] + '</div>');
	document.write('<div id="sectionlist_'	+ navCategories[nCnt] + '" class="sectionlist"	onMouseOver="pageSections_Show(' + quote + navCategories[nCnt] + quote + ', this, 1);" onMouseOut="pageSections_HideCurrent();">');
	document.write(navCategories[nCnt + 2]);
	document.write('</div>');
	document.write('</div>');
	nOffset += nWidth;
}

function showNavBar (nExtraLoading)
{
	if (nExtraLoading == 1)
		pageLoaded();
	for (nCnt = 0; nCnt < navCategories.length; nCnt += 3)
		divVisibility_Set("section_" + navCategories[nCnt], 0);
}

