//
// java.js
//
//   This is where all the javascript required by your design is written.
//

var timerId;
$(document).ready(function(){

  // This is required for the PNG fix to work.
  if( $.fn.pngfix != null )
    $("img[@src$=png]").pngfix();

  // This is some javascript to stop IE from displaying the img alt attributes
  // when you mouse over imagess.  If you would like IE to display the alt attributes,
  // just comment out the following 4 lines.  Don't worry, if you leave this in 
  // place, your ALT attributes are still readable by the search engines.
  var tmpalt;
  $("img").hover( 
    function(){ tmpalt = $(this).attr( "alt" ); $(this).attr( "alt", "" ); },
    function(){ $(this).attr( "alt", tmpalt ); });

  // This is code to handle all of the _linkover events.  It works by
  // creating a special Wrap class, adding it to the link and linkover
  // divs of each link and linkover pair, and assigning a hover event to
  // that.
  $("#news-46").addClass("Wrap-45-46").hide();
  $("#news-45").addClass("Wrap-45-46");
  $(".Wrap-45-46").hover(
    function(){ $("#news-46").show(); $("#news-45").hide(); },
    function(){ $("#news-45").show(); $("#news-46").hide(); });
  $("#news-48").addClass("Wrap-47-48").hide();
  $("#news-47").addClass("Wrap-47-48");
  $(".Wrap-47-48").hover(
    function(){ $("#news-48").show(); $("#news-47").hide(); },
    function(){ $("#news-47").show(); $("#news-48").hide(); });
  $("#news-50").addClass("Wrap-49-50").hide();
  $("#news-49").addClass("Wrap-49-50");
  $(".Wrap-49-50").hover(
    function(){ $("#news-50").show(); $("#news-49").hide(); },
    function(){ $("#news-49").show(); $("#news-50").hide(); });
  $("#news-54").addClass("Wrap-53-54").hide();
  $("#news-53").addClass("Wrap-53-54");
  $(".Wrap-53-54").hover(
    function(){ $("#news-54").show(); $("#news-53").hide(); },
    function(){ $("#news-53").show(); $("#news-54").hide(); });
  $("#news-56").addClass("Wrap-55-56").hide();
  $("#news-55").addClass("Wrap-55-56");
  $(".Wrap-55-56").hover(
    function(){ $("#news-56").show(); $("#news-55").hide(); },
    function(){ $("#news-55").show(); $("#news-56").hide(); });
  $("#news-58").addClass("Wrap-57-58").hide();
  $("#news-57").addClass("Wrap-57-58");
  $(".Wrap-57-58").hover(
    function(){ $("#news-58").show(); $("#news-57").hide(); },
    function(){ $("#news-57").show(); $("#news-58").hide(); });
  $("#news-60").addClass("Wrap-59-60").hide();
  $("#news-59").addClass("Wrap-59-60");
  $(".Wrap-59-60").hover(
    function(){ $("#news-60").show(); $("#news-59").hide(); },
    function(){ $("#news-59").show(); $("#news-60").hide(); });
  $("#news-62").addClass("Wrap-61-62").hide();
  $("#news-61").addClass("Wrap-61-62");
  $(".Wrap-61-62").hover(
    function(){ $("#news-62").show(); $("#news-61").hide(); },
    function(){ $("#news-61").show(); $("#news-62").hide(); });
  
  // This is code to handle the contact_hmenu menu
  $("#news-43").hide().addClass("allMenus");
  $("#news-44").mouseover(function(e){
    e.preventDefault();
    $(".allMenus").hide();
    $("#news-43").show();
    // Remove the following 2 lines if you don't want this menu to dissappear
    // automatically.  Change how long the menu stays visible by changing
    // the 4000 to another number of milliseconds
    clearTimeout( timerId );
    timerId = setTimeout( '$("#news-43").hide()', 2500 );
  });
  
  // This is code to handle the ourwork_hmenu menu
  $("#news-52").hide().addClass("allMenus");
  $("#news-51").mouseover(function(e){
    e.preventDefault();
    $(".allMenus").hide();
    $("#news-52").show();
    // Remove the following 2 lines if you don't want this menu to dissappear
    // automatically.  Change how long the menu stays visible by changing
    // the 4000 to another number of milliseconds
    clearTimeout( timerId );
    timerId = setTimeout( '$("#news-52").hide()', 2500 );
  });

});
