$(function() {
    // run the code in the markup!
    $('#ContentWrapper pre code').each(function() {
        eval($(this).text());
    });
});

// MAIN SETTING CYCLE
$.fn.cycle.defaults.speed   = 1500;
$.fn.cycle.defaults.timeout = 1500;


// EFFECT SETTING CYCLE
$('#FadingImages').cycle('fade');


// ACTIVATION OF LIGHTBOX
$(function() {
	$('#gallery a').lightBox({fixedNavigation:true});
});

// ACTIVATION OF ZOOMPLE
$(document).ready(function() {
		$('.zoomple').zoomple({source:'rel'});
	});

// ACTIVATION AND CONFIG OF IMAGESWAPPER
	$.swapImage(".swapImage");
	$.swapImage(".swapImageClick", true, true, "click");
	$.swapImage(".swapImageDoubleClick", true, true, "dblclick");
	$.swapImage(".swapImageSingleClick", true, false, "click");
	$.swapImage(".swapImageDisjoint", true, true, "click", "click");
	$.swapImage(".swapImageDisjointOver", true, true, "mouseenter", "mouseleave");


var site_functions = {
	setCollectionImage : function(path1, path2, filename) {
		$('#enlarge').attr('src', path1+filename);
		$('#enlarge_link').attr('rel', path2+filename);
	},
	loadContent : function(url){
		$('#ContentWrapper').load(url);
	}
}

