
var gallery_step_02		= 10;
var gallery_time_02		= 50;
var gallery_breite_02		= 0;

var gallery_direction_02	= "left";
var gallery_moving_02		= false;
var gallery_move_timer_02	= false;

var gallery_i_02 = 0;

function move_02()
{
	gallery_breite_02 = (getWidth('first_row_02') > getWidth('second_row_02')) ? getWidth('first_row_02') : getWidth('second_row_02');
	if( (this.gallery_i_02 <= 0 && this.gallery_direction_02 == 'left') || (this.gallery_i_02 >= -(this.gallery_breite_02 - getWidth('gallery_rect_02')) && this.gallery_direction_02 == 'right') )
	{
		document.getElementById('first_row_02').style.left = this.gallery_i_02;
		document.getElementById('second_row_02').style.left = this.gallery_i_02;
		
		if( this.gallery_direction_02 == 'left' )				
			this.gallery_i_02 += this.gallery_step_02;
		else
			this.gallery_i_02 -= this.gallery_step_02;
	}
}

function start_stop_move_02(direction)
{
	this.gallery_direction_02 = direction;
	
	if( this.gallery_move_timer_02 == false )
	{
		this.gallery_move_timer_02 = window.setInterval( "move_02()", this.gallery_time_02 );
	} else {
		window.clearInterval( this.gallery_move_timer_02 );
		this.gallery_move_timer_02 = false;
	}
}

function getHeight_02(obj) {
	var ret=0;
	if (typeof obj != 'object') {
		obj = document.getElementById(obj);
	}
	if (obj.offsetHeight) {
		return obj.offsetHeight;
	}
}

function getWidth_02(obj) {
	var ret=0;
	if (typeof obj != 'object') {
		obj = document.getElementById(obj);
	}
	if (obj.offsetWidth) {
		return obj.offsetWidth;
	}
}

