/////////
//	Girl Page Gallery
///////////////////////////
function showPicture(index)
{
	pics_wrap.select('img:not([class=hide])').invoke('addClassName', 'hide');
	thumb_wrap.select('.selected').invoke('removeClassName', 'selected');

	Element.removeClassName(pics[index], 'hide');
	Element.addClassName(thumbs[index], 'selected');
}

var gal, slide, scroll;

function init_gallery()
{
	gal = new ImageGallery({
			thumbPrefix: 'sml_',
			imagePrefix: 'img_',
			selectedClass: 'selected',
			thumbClass: 'thumb'
	});
	
	slide = new Slidezilla('pic_more', {
			num_visible: 7,
			increment: 1,
			content_class: 'pics_wrap',
			up_class: 'arrow_top',
			down_class: 'arrow_down'
	});

//	scroll = new scrollwheel( { container_id: 'pics_wrap', callback: scroll_callback } );
}

function scroll_callback(e, d)
{
	if(d > 0)
		imgPrevious();
	else if(d < 0)
		imgNext();
}

function imgPrevious()
{
	reloadAd('billboardAd', 300, 250);
	reloadAd('banner', 728, 90);
	gal.showPrevious();
	slide.up();
}

function imgNext()
{
	reloadAd('billboardAd', 300, 250);
	reloadAd('banner', 728, 90);
	gal.showNext();
	slide.down();
}


//////
//	Application
////////////////////
function step_one()
{
	var form = $('step_one');

	form.submit();

//	var form_values = form.serialize();

//	new Req.ajax({ div: 'steps', url: '/ajax/cute_college_girl/apply_info', options: { parameters: form_values } });
}

function showMessage()
{
	$('upload_message').update('Hang on, this might take a minute....');
}