$(function(){
	// Accordion
	$("#accordion").accordion({ header: "h3" });

	// Tabs
	$('#tabs').tabs();


	// Dialog			
	$('#dialog').dialog({
		autoOpen: false,
		width: 600,
		buttons: {
			"Ok": function() { 
				$(this).dialog("close"); 
			}, 
			"Cancel": function() { 
				$(this).dialog("close"); 
			} 
		}
	});
	
	// Dialog Link
	$('#dialog_link').click(function(){
		$('#dialog').dialog('open');
		return false;
	});

	// Datepicker
	$('#datepicker').datepicker({
		inline: true
	});
	
	// Slider
	$('#slider').slider({
		range: true,
		values: [17, 67]
	});
	
	// Progressbar
	$("#progressbar").progressbar({
		value: 20 
	});
	
	//hover states on the static widgets
	$('#dialog_link, ul#icons li').hover(
		function() { $(this).addClass('ui-state-hover'); }, 
		function() { $(this).removeClass('ui-state-hover'); }
	);
});

<!--//--><![CDATA[//><!--
var startList = function()
{
	if (document.all && document.getElementById)
	{
		cssdropdownRoot = document.getElementById("TopMenu");
		
		if (cssdropdownRoot != null && typeof(cssdropdownRoot) != "undefined")
		{
			for (x = 0; x < cssdropdownRoot.childNodes.length; x++)
			{
				node = cssdropdownRoot.childNodes[x];
				if (node.nodeName == "LI")
				{			
					node.onmouseover = function()
					{
						this.className += " over";
					}
					
					node.onmouseout = function()
					{
						this.className = this.className.replace(" over", "");
					}
				}
			}
		}
	}
}

if (window.attachEvent)
	window.attachEvent("onload", startList)
else
	window.onload = startList;
//--><!]]>

