
function Rotator(block_id,block_class)
{this._block_id=block_id;this._block_class=block_class;this._block_count=$j('.'+this._block_class).length;this._current_block=0;this.rotate=function(type){$j('#'+this._block_id+this._current_block).hide();var el;if(type=='next')
{this._current_block++;el=$j('#'+this._block_id+this._current_block);if(!el.get(0))
{this._current_block=0;el=$j('#'+this._block_id+'0');}}
if(type=='prev')
{this._current_block--;el=$j('#'+this._block_id+this._current_block);if(!el.get(0))
{this._current_block=this._block_count-1;el=$j('#'+this._block_id+this._current_block);}}
el.fadeIn('fast');};this.getCount=function(){return this._block_count;};}
$j(function()
{var info_timer_id;r1=new Rotator('rotating','rotating');r2=new Rotator('third-dynamic','slide');if(r2.getCount()>0)
{info_timer_id=window.setInterval("r2.rotate('next')",10000);}
$j('.home_slideshow').hover(function()
{window.clearInterval(info_timer_id);},function()
{info_timer_id=window.setInterval("r2.rotate('next')",10000);});});
