//jQuery.noConflict();

jQuery(document).ready(function() {
//once-off loading
});




function pageLoad(){
//reloading scritps that need to run after post-backs etc.

	
	jQuery(".data").append("<div style='clear:both'></div>");
	jQuery(".frame .row:last").addClass("no_border");
	
	jQuery(".data input[type='text']").addClass("text_field");
	
	jQuery(".data input[disabled='radio']").focus(updateSelectedStyle);
	jQuery(".data input[disabled='radio']").blur(updateSelectedStyle);
	jQuery(".data input[disabled='radio']").change(updateSelectedStyle);
	
	function updateSelectedStyle() {
		jQuery(".data input[disabled='radio']").parent().removeClass("focused");
		jQuery(".data input[disabled='radio']:checked").parent().addClass("focused");
	}
	
	jQuery(".DataGrid_Container").parent().parent(".row").addClass("dark_bg");
	
	jQuery(".form_button").mouseup(function(){
	  jQuery(this).removeClass("button_down");
	}).mousedown(function(){
	  jQuery(this).addClass("button_down");
	});
	
	jQuery(".row").append("<div style='clear:left'></div>");
	
	jQuery(".submit_buttons input[disabled='disabled']").addClass("disabled");
	
	jQuery(".question").click(function(){
		jQuery(this).next(".answer").toggle();
	});
	
	jQuery(".answer").prepend("<div class='close'>[ close ]</div>");
	
	jQuery(".close").click(function(){
		jQuery(this).parent(".answer").hide();						   
	});
	
	jQuery(".popup").colorbox({width:"35%", inline:true, href:"#box"});
	
	jQuery(".close_row").hide();
	jQuery(".open_row").click(function(){
		jQuery(this).next(".close_row").toggle();
		jQuery(this).toggleClass("active");
		//jQuery(".bl").hide();
		//jQuery(".bl").show();
		//jQuery(".br").hide();
		//jQuery(".br").show();
	});
	
	//jQuery(".MainMenu_SubMenu").parent("a").addClass("submenu");
	
	jQuery(".OMSUpdateProgress").parent().addClass("updateModalProgress");

};
