/* Copyright (c) 2010, Accolade Designs */

$(document).ready(function(){$("#loadingDialog").dialog({bgiframe:true,autoOpen:false,resizable:false,modal:true,position:'center',dialogClass:'loadingDialog',width:220,minHeight:88,height:88});});var gg=true;function showLoading(){if(!gg){$("#loadingDialog").dialog('open');}gg=false;};function hideLoading(count){if($("#loadingDialog").dialog("isOpen")){setTimeout("$('#loadingDialog').dialog('close');",300);}else{if(!eP(count)){count=0;}count++;if(count<5){setTimeout('hideLoading('+count+');',500);}}};$.fn.radioRow=function(){return this.mouseenter(function(e){$(this).addClass('highlightRow');}).mouseleave(function(e){$(this).removeClass('highlightRow');}).click(function(e){$('.clickedRow').removeClass('clickedRow');$(this).find(':radio').attr('checked','checked').end().addClass('clickedRow');});};$.fn.radioCell=function(){return this.mouseenter(function(e){$(this).addClass('highlightCell');}).mouseleave(function(e){$(this).removeClass('highlightCell');}).click(function(e){$(this).prev(':radio').attr('checked','checked');});};function scrollToTarget(target){var eJ=$(target).offset().top;$('html,body').animate({scrollTop:eJ},100);};$.fn.scrollToTarget=function(){var eJ=this.offset().top;$('html,body').animate({scrollTop:eJ},100);return this;};$.fn.fY=function(params){var target=this;var width=params!=null?params.width:0;if(width<=0){width=150;}target.find('.dropDownValue').css({'width':width+'px'}).next().css({'left':(width-8)+'px'});target.find('.dropDownValue, .dropDownImg').unbind().click(function(e){e.stopPropagation();if(target.find('.dropDownMenu:visible')[0]!=null){target.find('.dropDownMenu').hide(10);}else{var offset=target.find('.dropDownValue').position();target.find('.dropDownMenu').css({'top':(offset.top+22),'left':(offset.left)}).show(10);eG=true;}});target.find('.dropDownMenu').find('a').click(function(e){e.preventDefault();target.find('.dropDownValue').html($(this).html());target.find('.dropDownMenu').slideUp(100);var value=$(this).attr("title");$(this).parent().parent('ul').find('.dropDown-select').removeClass('dropDown-select');$(this).addClass('dropDown-select');if(params.click!=null){params.click(value);}});if(params.defaultFn!=null){params.defaultFn();}if(params.defaultValue!=null){target.find('.dropDownValue').html(params.defaultValue);$(this).find("a[title='"+params.defaultValue+"']").addClass('dropDown-select');}return this;};function enlargeProductThumbnail(){$('.imgThDiv').mouseenter(function(event){var pos=$(this).offset();$(this).next().css({'top':pos.top-80,'left':pos.left+150}).show();}).mouseleave(function(event){$(this).next().fadeOut('fast');});}

