// JavaScript Document

//function startGallery(g){

var prePointer = 0;

var currentPointer = 0;

var arrowHeight = 80;

var aboutBoxWidth = 619;

var theLeft,theTop;
$(document).ready(function() {
	
	$( "#accordion" ).accordion();
	var titles = $("#aboutTitle ul li");

	$(".aboutBox").eq(currentPointer).css('width',aboutBoxWidth+'px');

	if(jQuery.isEmptyObject(titles)){
		alert("No gallery div named " + g + "found!");
	}else{

		titles.hover(function(){
			currentPointer = titles.index(this);
			$("#naviArrow").animate({'margin-top':arrowHeight*currentPointer+'px'},200);
		},function(){
		});
		
		titles.click(function() {
			$(".aboutBox").eq(prePointer).animate({'width':'0px'},300);
			$(".aboutBox").eq(currentPointer).animate({'width':aboutBoxWidth+'px'},300);
			prePointer=currentPointer;
		});
	}
	jQuery("#destinations_show_btn").hover(function() {
		    theLeft = jQuery(this).position().left - 150;
			theTop = jQuery(this).position().top+30;
			jQuery("#destinations_floating_box").css("left",theLeft).css("top",theTop);
			jQuery("#destinations_floating_box").slideToggle(300);		
		},function(){
			jQuery("#destinations_floating_box").slideToggle(300);
		});

});




