/* Author: Matthew Wrather */

$(document).ready(function(){
	$('#main-box-text').jScrollPane({
		showArrows: true,
		animateScroll: true
	});
});

/*
var $up,
		$down,
		$box,
		$text,
		$arrows,
		boxHeight,
		textHeight,
		heightDifference,
		distanceToGo,
		scrollFactor = 10; // how many milliseconds per pixel the content div scrolls


$(function() {
	// remove before launch: bg switcher
	$('#switch-bg').click(function(){
		$('body').toggleClass('white');
		return false;
	});


	$up = $('#up');
	$down = $('#down');
	$box = $('#main-box');
	$text = $('#main-box-text');
	$arrows = $('#arrows');
	boxHeight = $box.height();
	
	// disable normal click behavior
	$up.click(function() { return false; });
	$down.click(function() { return false; });

	// progressively enhance the scroller stuff
	$text.css('overflow', 'visible');
	$arrows.show().css('margin-top', (420 - $arrows.height()) / 2 + 'px');

	$down.hover(function() {
		heightDifference = textHeight - boxHeight;
		distanceToGo = heightDifference + parseInt($text.css('top'));
		$text.animate({'top': '-' + heightDifference + 'px'}, distanceToGo * scrollFactor);
	}, function() {
		$text.stop();
	});

	$up.hover(function() {
		$text.animate({'top': '0'}, parseInt($text.css('top')) * -scrollFactor);
	}, function() {
		$text.stop();
	});

});

window.onload = function() {
	// Chrome only knows this once the page has rendered
	textHeight = $text[0].scrollHeight;
};

*/
