function jGrowlTheme(type, header, message) {
    jGrowlTheme(type, header, message, 10000);
}

function jGrowlTheme(type, header, message, life) {
    	
	switch(type) {
		case "error": 
			
			var theText 		= '<img src="http://assets.gadball.com/images/messageboxes/error.png" width="16px" class="img-thumb" /><span class="separator">&nbsp;</span>' + message;
	
			var themeAnimate = 	function() {
											setTimeout(function() { 
												$('img.img-thumb').animate({marginLeft: "-.5em"});
												$('.separator').animate({marginLeft: "-.3em"});
												$('div.jGrowl div.themed div.header').animate({marginLeft: "4.7em"}, 500);
												$('div.jGrowl div.themed div.message').animate({marginLeft: "6em"}, 1000);
											}, 10);
										}
					
			$.jGrowl(theText, {
						header: header,
						theme: 'themed', 
						life: life,
						open: themeAnimate
			});
			            
		break;
		case "success":
			
			var theText 		= '<img src="http://assets.gadball.com/images/messageboxes/success.png" width="16px" class="img-thumb-themed2" />' + message;
			var themedAnimate = 	function() {
											setTimeout(function() { 
												$('img.img-thumb-themed2').animate({right: "18em"}, 1000);
											}, 10);
										}
					
			$.jGrowl(theText, {
						header: header,
						theme: 'themed2', 
						life: life,
						open: themedAnimate
			});
			
		break;
		
		case "info":
			
			var theText 		= '<img src="http://assets.gadball.com/images/messageboxes/info.png" width="16px" class="img-thumb-themed3" />' + message;
			var themedAnimate = 	function() {
											setTimeout(function() { 
												$('img.img-thumb-themed3').animate({right: "18em"}, 1000);
											}, 10);
										}
					
			$.jGrowl(theText, {
						header: header,
						theme: 'themed3', 
						life: life,
						open: themedAnimate
			});
			
		break;
	}
}
