$(function(){
	
	makeSlider('#shows-slider', 'fold', 500, 5000, false, 0);
		
	 flickrFeed_user_all("62332245@N08", "#flickr", 10);
	 flickrFeed_set("62332245@N08", "72157626608098440", "#picoday", 1);
	 $(window).load(
	 	function() {
			$('.daypic').resizePropToWidth(600);
			$('<a href="http://www.flickr.com/photos/d93/" style="top: -15px; font-family: arial, sans-serif; font-size: .8em;">View all photos</a>').appendTo('#flickr');
		}
	 );
	 
	 
	 $('.personality .info').append('<a href="#">[<span class="plusminus">+</span>] <span class="info-link">Click for more info</span></a>').children('ol').hide();
	 $('.personality .info a').each(function() {
	 	$(this).toggle(function() {
			$(this).parent().children('ol').slideDown();
			$(this).children('span.plusminus').text('-');
			$(this).children('span.info-link').text('Click to hide info');
			$(this).parent().children('h3').attr('id', 'current-person');
			return false;
		}, function() {
			var new_position = $('#current-person').offset();
			window.scrollTo(new_position.left,new_position.top);
			$(this).parent().children('ol').slideUp();	
			$(this).children('span.plusminus').text('+');
			$(this).children('span.info-link').text('Click for more info');
			$(this).parent().children('h3').attr('id', '');
		});
	 });
	 
	 $('#now-playing marquee').marquee('pointer').mouseover(function () {
            $(this).trigger('stop');
        }).mouseout(function () {
            $(this).trigger('start');
        }).mousemove(function (event) {
            if ($(this).data('drag') == true) {
                this.scrollLeft = $(this).data('scrollX') + ($(this).data('x') - event.clientX);
            }
        }).mousedown(function (event) {
            $(this).data('drag', true).data('x', event.clientX).data('scrollX', this.scrollLeft);
        }).mouseup(function () {
            $(this).data('drag', false);
        });
});
