
function JockerCard()
{
}


var Slide = {	

	inline:		null,	
	top:		0,
	delta:		410,
	h:			0,
	curr:		0,
	pos:		[],

	setCurr : function(id)
	{
		this.curr = id;
		this.top = this.pos[this.curr] ? this.pos[this.curr] : 0;
	},

	sets : function()
	{
		$("#scrolling").css({top: this.top});
		//alert(this.top);
	},

	down : function(id) 
	{	
		this.h = $('#' + id).height();
//debugger;
		if (this.top > (-this.h  + this.delta))
		{
			
			this.top -= this.delta;

			if (this.top < -this.h)
			{
				this.top = (-this.h + this.delta);
				$('#img-next').hide();
			} 
			else
			{
				$('#img-prev').show();
			}
			
			// Hide
			$("#"+id).animate({top:this.top}, 1000);
			this.pos[this.curr] = this.top;
			// -			
		}
		else
		{
			$('#img-next').hide();
		}
	},

	up : function(id) 
	{
		
		if (this.top <= 0)
		{
			
			this.top += this.delta;

			if (this.top > 0)
			{
				this.top = 0;
				$('#img-prev').hide();
			} 
			else
			{
				$('#img-next').show();
			}
			
			$("#"+id).animate({top:this.top}, 1000);
		}
		else
		{
			$('#img-prev').hide();
		}
	}

	

}
