/**
 * Подсветка строк в таблице при навидении
 * 
 * @params		hash		options		Допустимые значения
 * 										backgroundColorActive		- Цвет подсветки активной строки. По умолчанию: #ECE9D6;
 * 										backgroundColor				- Цвет подсветки пасивной строки.
 */
jQuery.fn.highlight = function( options )
{
	this.backgroundColorActive = '#ECE9D6';
	this.backgroundColor = '';
	
	if ( options != undefined )
		for ( var i in options )
			this[i] = options[i];
	
	var obSelf = this;
	
	return this.each(function()
	{
		jQuery('tr',this).hover(
			function()
			{
				td_active = $(this).children('td');
				td_active.css({'backgroundColor': obSelf.backgroundColorActive});
				td_active.find('div.reviews > ul').show().fadeTo(200,1);
				td_active.find('a.order').hide();
				td_active.find('img.order').show().fadeTo(200,1);
				return true;
			},
			function()
			{
				td_active = $(this).children('td');
				td_active.css({'backgroundColor': obSelf.backgroundColor, 'cursor':''});
				td_active.find('div.reviews > ul').stop().hide().css('opacity',0);
				td_active.find('a.order').show();
				td_active.find('img.order').stop().hide().css('opacity',0);
				return true;
			}
		);
	});
};
