// JavaScript Document

/*
* Add events to buttons for mouseover and mouse out effects.
*/

//Execute on page load.
$(function(){ 
	//Toggle buttons to their on state when mouseing over these buttons.
	$("a.jqButton").mouseover(		
		function(){
			$(this).children().switchBtnOn();
		}
	);
	//Toggle buttons to their off state when mousing out of these buttons.
	$("a.jqButton").mouseout(		
		function(){
			$(this).children().switchBtnOff();
		}
	);
	//Toggle buttons to their on state when focussed.
	$("a.jqButton").focus(		
		function(){
			$(this).children().switchBtnOn();
		}
	);
	//Toggle buttons to their off state when blurred.
	$("a.jqButton").blur(		
		function(){
			$(this).children().switchBtnOff();
		}
	);
	
	//Toggle buttons to their on state when mouseing over these buttons.
	$("input.jqButton").mouseover(		
		function(){
			$(this).switchBtnOn();
		}
	);
	//Toggle buttons to their off state when mousing out of these buttons.
	$("input.jqButton").mouseout(		
		function(){
			$(this).switchBtnOff();
		}
	);
	//Toggle buttons to their on state when mouseing over these buttons.
	$("input.jqButton").focus(		
		function(){
			$(this).switchBtnOn();
		}
	);
	//Toggle buttons to their off state when mousing out of these buttons.
	$("input.jqButton").blur(		
		function(){
			$(this).switchBtnOff();
		}
	);
});
