// JavaScript Document

$(document).ready(function() {
	
$(".read_more").css('display', 'none');
$(".read_more").css('visibility', 'visible');

	
$(".read_more_link").click(function(event){
     $(".read_more").slideToggle('slow');
     //alert($("#main_section").height());
     if ($(".read_more_link").html() == "Hide"){
     	$(".read_more_link").html('Read more');
     }
     else {
     	 $(".read_more_link").html('Hide');
     }
   });
	
$("a#moreSigs").click(function(event){
	event.preventDefault();
   $("#plea_sigs").slideToggle(2000);
   });	
   

$("a#moreProcs").click(function(event){
	event.preventDefault();
   $("#proc_sigs").slideToggle(2000);
   });	

//$.jatt({
//  // options that can be modified by metadata
//  direction   : 'n',     // direction of tooltip
//  followMouse : false,    // tooltip follows mouse movement
//  content     : 'title', // attribute containing tooltip text
//  speed       : 300,     // tooltip fadein speed
//  local       : false,   // if true, the script attachs the tooltip locally; if false, the tooltip is added to the body
//  xOffset     : 10,      // x distance from mouse (no negative values)
//  yOffset     : 10,      // y distance from mouse (no negative values)
//  zIndex      : 1000,    // z-index of tooltip
//
//  // options not supported by metadata
//  live        : false,                 // use live event support?
//  metadata    : 'class',               // attribute that contains the metadata, use "false" (no quotes) to disable the metadata.
//  activate    : 'mouseenter focusin',  // how tooltip is activated
//  deactivate  : 'mouseleave focusout', // how tooltip is deactivated
//
//  // change tooltip, screenshot and preview class
//  tooltip     : '.tooltip',            // tooltip class 
//  screenshot  : 'a.screenshot',        // screenshot class
//  preview     : 'a.preview',           // preview class
//  
//  // tooltip & preview ID (div that contains the tooltip)
//  tooltipId   : 'tooltip',             // ID of actual tooltip
//  previewId   : 'preview'              // ID of screenshot/preview tooltip 
// });   
   
$("a.noclick").click(function(event){
	return false;
	event.preventDefault();
   });	   
   
$("#thesearch").focus(function() {
      $(this).val('');
	});  

   
});//end document ready

$(window).load(function() {
	 //  var middleHeight = $("#main_section").height();
	   var leftHeight = $("#left_bar").height();
	  // var rightHeight = $("#right_bar").height();
	  // var wideHeight = $("#wide_main_section").height();
	   var bottomHeight = $("#bottom_section").height();
	   var theSpacer = 60; // 46 is even

	   if ($.browser.msie ){
	   		if ($.browser.version <= 7.0){
	   		  theSpacer = 24; // 46 is even
	   		  if (leftHeight < (bottomHeight-theSpacer)){
				  $("#left_bar").height(bottomHeight-theSpacer);
			   }
	   	}else{
	   		theSpacer = 60; // 46 is even	
	   			if (leftHeight < (bottomHeight-theSpacer)){
			  $("#left_bar").height(bottomHeight-theSpacer);
		   }
	   	}
	   }else{
		 // alert("l"+leftHeight+" B"+bottomHeight+" s"+theSpacer);

		   if (leftHeight < (bottomHeight-theSpacer)){
			  $("#left_bar").height(bottomHeight-theSpacer);
		   }
	   }


	});

