/**
 * @author Chris
 */

Base = {
	browserIE: false,
	defaultURL: window.location.protocol + '//' + window.location.host,
	displayGenericError: function(title,errorText){
		
		if(title == null) title = 'Error';
		if(errorText == null) errorText = 'An error occurred, please try later.';
		
		$.blockUI({
            theme:     true, 
            title:    title, 
            message:  '<p>' + errorText + '</p>', 
            timeout:   3000
		});
	},
	animateLogo: function(){
		$('#logoImage').animate({
				left: '+=10',
				top: '+=10',
				height: 125,
				width: 125
			},1000,function(){
				$('#logoImage').animate({
						'left': '-=10'
					},250,function(){
						$('#logoImage').animate({
								'left': '+=10'
							},250,function(){
								$('#logoImage').animate({
										'left': '+=760'
									},500,function(){
										//Now fade in the header pictures
										$('.headerImage').fadeIn('normal');
									}
								);
							}
						);
					}
				);
			}
		);
	}
}

$(document).ready(function(){	
	Base.animateLogo();
	
});


