//Event.observe(window, 'load', function() {
document.observe("dom:loaded", function() {


if($('selector')){
	$('selector').observe('click', dropCategories);
	$('selector').setStyle({cursor: "pointer"});
  }
  
if($$('.pledgeSubmitBtn')){
	$$('.pledgeSubmitBtn').invoke('observe', 'click', invokePledgeSubmit);
  }
  
  
});


function dropCategories(event){
	
	event.stop();
	element = Event.element(event);
	dropElement = $('category-dropdown');
	
	if(dropElement.getStyle('display') != 'none'){
		
		$$('html').first().stopObserving('click');
		
		new Effect.SlideUp($('category-dropdown'), {duration: 0.25, transition: Effect.Transitions.Quad.easeIn, queue: { position: 'end', scope: 'dropdown', limit: 2 }});
		
		
		
	}else{

		new Effect.SlideDown($('category-dropdown'), {duration: 0.25, transition: Effect.Transitions.Quad.easeOut, queue: { position: 'start', scope: 'dropdown', limit: 2 }});
	}
	
		// hide dropdown if click fired is not inside zoom
		$$('html').first().observe('click', function(e) {
		
		
		
		
		if($('body_ifr')){
		  dropClick = true;
		} else {
		  dropClick = false;  
		}
		var click_in_box = e.findElement('#category-dropdown'),
		  drop_display  = dropElement.getStyle('display');
		if (drop_display == 'block' && !click_in_box && !dropClick) {
			
			new Effect.SlideUp($('category-dropdown'), {duration: 0.25, transition: Effect.Transitions.Quad.easeIn, queue: { position: 'end', scope: 'dropdown', limit: 1 }});
		}
		});
}

//pop window functions
function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=1,width=800,height=600');");
}

/*------------------------------Launch Modal Window Functions -------------*/

function setupZoom(){
	var my_div = document.createElement('div');
	my_div.id="ajaxResult";
	document.body.appendChild(my_div);
	FancyZoomBox.init();
	$$(".isModal").each(function(el) { new FancyZoom(el); });
	$(document).observe('zoom:zoomLoaded', initTabs);
	$(document).observe('notes:notesLoaded', initNotes);
	$(document).observe('fund:fundLoaded', initFund);
	
}

function popZoom(element, url, params, customEvent){
			element = $(element);
			if(!params){
				params = 'par=1';	
			}
			if(!customEvent){
				customEvent = 'noEvent:nothingLoaded';
			}
			new FancyZoomPop(element, url, params, customEvent);
		
}

function popEssay(){
			element = $('banner');
			params = 'par=1';	
			url = '/ajax/photo-essay.php';
			customEvent = 'noEvent:nothingLoaded';
			new FancyZoomPop(element, url, params, customEvent);
			
			$('boxMiddle').setStyle({backgroundColor: '#333333'});
		
}


/*------------------------------ Fund Raiser Email Form -------------------*/


function invokePledgeSubmit(event){
	
	event.stop();
	element = Event.element(event);
	
	var userEmail = $('pledge_email').value;
										
	new Ajax.Request('/constantcontact/AddAContact.php', {
			method: 'post',
			parameters: {required_params:'email_address', email_address:userEmail}, 
			onComplete: function(transport){
				$('freeform').submit();
			}
	
});
	
	
}

function initFund(){
	
	
	//allow the zoom container to resize
		$('zoom').setStyle({height: 'auto'});
		
		$('sendBtn').observe('click', validateFund);
		
		$$('.shareField').invoke('observe', 'focus', clearVal);
		$$('.shareField').invoke('observe', 'blur', setVal);
		$$('.shareField').each(function(el) {
			el.value = el.readAttribute('title');
		});
	
}

function validateFund(){
	
	$$('.required').each(function(el) {
			
			errorElement = el.up().next('.shareError');
			
			if(el.value === el.readAttribute('title')){
				
				displayError(el, errorElement);
				
			/*} else if(el.hasClassName('email')){				  
			
				var validateEmail = CheckEmail(element.value);
			
				if(validateEmail !== ""){
					
					displayError(el, errorElement);
					
					errorElement.update('Invalid Email');
				} else {
					
					removeError(el, errorElement);	
				}*/
					  
			} else {
			
					removeError(el, errorElement);
			   
		   }
	});
	
	//use an if cond to check something about the error message
	//maybe el.addclassname invalid and a remove for each?
	
	if ($$('.invalid').length === 0){
		
		$('sendBtn').stopObserving('click', validateFund);
		sendFund();	
		
	}
	
}

function removeError(el, errorElement){
	
	if(errorElement.getStyle('display') != 'none'){
		el.removeClassName('invalid');
		new Effect.BlindUp(errorElement, {duration: 0.5});
	}
}

function displayError(el, errorElement){
	
	if(errorElement.getStyle('display') == 'none'){
		new Effect.BlindDown(errorElement, {duration: 0.5});
		el.addClassName('invalid');
	
	}else if(errorElement.getStyle('display') != 'none'){
		Effect.Shake(errorElement, { duration: .4, distance: 4 });
	}
	
}


function sendFund(){
	
	$('progressBar').appear();
	
	$('emailFund').request({
			onComplete: function(transport) {
				//alert(transport.responseText);
				
				$('tab1').setStyle({height: $('tab1').getHeight()+'px'});
				$('emailForm').fade({duration: 0.5, queue: { position: 'end', scope: 'thanks' }});
				new Effect.Morph('tab1', {
					style: {
					height: ($('thankYou').getHeight()+15) +'px'
					}, // CSS Properties
					duration: 0.5, // Core Effect properties
					queue: { position: 'end', scope: 'thanks' }
				});

				$('thankYou').appear({duration: 0.5, queue: { position: 'end', scope: 'thanks' }});
			}
   	
		});
	
}


/*------------------------------ Modal Notes Manage ------------------------*/

function initNotes(){
	$$('.removeNote').invoke('observe', 'click', deleteNote);
}

function deleteNote(event){
	element = Event.element(event);
	var twitterID = $(element).id;
	var noteID = $(element).up().id;
	
	dropElement = $(element).up();
	
	//alert(twitterID);
	//twitterID needs to be a string
	
	new Ajax.Request('/ajax/deleteName.php', {
		method: 'post',
		parameters: {twitID: twitterID, id: noteID}, 
		//onComplete: function(transport){
		onSuccess: function(){
    		//alert('note deleted');
			//Effect.DropOut(dropElement);
		}

	});
	
	Effect.DropOut(dropElement);

	
}


/*------------------------------ Modal Tabs Function ---------------------*/
function initTabs() {
		
		$('boxMiddle').setStyle({backgroundColor: '#EAEAEA'});
		
		var tabLink = Element.extend($$('.tab'));
		tabLink.invoke('observe', 'click', swapTabs);
		
		//allow the zoom container to resize
		$('zoom').setStyle({height: 'auto'});
		$('addEmail_btn').observe('click', addEmail);
		
		$('sendBtn').observe('click', validateForm);
		

		
		$$('.shareField').invoke('observe', 'focus', clearVal);
		$$('.shareField').invoke('observe', 'blur', setVal);
		$$('.shareField').each(function(el) {
			el.value = el.readAttribute('title');
		});
		
		//copy to clipboard function
		if($('copyBtn')){
			$('copyBtn').observe('click', function(){
				var videoEmbedCode = $('vidCode');
				copy(videoEmbedCode);
			});
		}
		
	}
	
	function addEmail(event){
		//element = Event.element(event);
		element = $('addEmail_field');
		var newEmail = $('addEmail_field').value;
		var emailBox = $('emailHolder');
		var emails = emailBox.innerHTML;
		
		if(!element.value.strip().empty() && element.value != element.readAttribute('title')){
			
			//check for a validate address
			var validateEmail = CheckEmail(element.value);
			var errorElement = $('error_email');
			if(validateEmail !== ""){
				errorElement.update(validateEmail);
				//animate error message
				new Effect.BlindDown(errorElement, {duration: 0.5});
				if(errorElement.getStyle('display') != 'none'){
					Effect.Shake('error_email', { duration: .7, distance: 4 });
				}

			} else {
			
				//fade error message if it exists (red message)
				if($('error_email').getStyle('display') != 'none'){
					new Effect.BlindUp($('error_email'), {duration: 0.5, queue: { position: 'end', scope: 'email' }});
				}
				
				//check if the email list is empty
				if(emails.strip().empty()){
					var emailElement = "<div class='addedEmail'><div class='emailToPost' style='padding-top:15px;'>"+newEmail.strip()+"</div> <div class='removeEmail' style='cursor:pointer; float: right; padding-top:15px;'>remove</div><div class='clearFixAdded'>&nbsp;</div></div>";
				} else {
					
					var emailElement = "<div class='addedEmail' style='display:none;'><div class='emailToPost'>"+newEmail.strip()+"</div> <div class='removeEmail' style='cursor:pointer; float: right;'>remove</div><div class='clearFixAdded'>&nbsp;</div></div>";
				}
				
				emailBox.insert(emailElement);

				
				//remove hint message if exists
				if(emails.include('emailsHint')){
					new Effect.BlindUp($('emailsHint'), {duration: 0.5, queue: { position: 'end', scope: 'email' }, afterFinish:function(){$('emailsHint').remove();}});
				}
				
				
				if($('emailHolder').getStyle('display') == 'none'){
					new Effect.BlindDown($('emailHolder'), {duration: 0.5, queue: { position: 'end', scope: 'email' }});

				}
				
				//fade in the new email message
				$$('.addedEmail').each(function(el) {
					if(el.getStyle('display') == 'none'){
						new Effect.BlindDown(el, {duration: 0.5, queue: { position: 'end', scope: 'email' }});
					}
				});
				
				$$('.removeEmail').invoke('observe', 'click', deleteEmail);
				
				//reset the message
				element.value = element.readAttribute('title');
			}
		}
	}
	
	function validateForm(event) {
	event.stop();
	element = Event.element(event);
	
	var emailField = $('emailHolder').innerHTML;
	var nameField = $('senderName');
	var senderEmail = $('senderEmail');
	
	
	
	var validSenderEmail = CheckEmail(senderEmail.value); 
	
		if(validSenderEmail != ""){
			
			var senderError = $('error_senderEmail');
			var senderEmailCheck = "invalid";
			senderError.update(validSenderEmail);
			//animate error message
			if(senderError.getStyle('display') == 'none'){
			new Effect.BlindDown(senderError, {duration: 0.5});
			
			}else if($('error_senderEmail').getStyle('display') != 'none'){
				Effect.Shake('error_senderEmail', { duration: .7, distance: 4 });
			}
		
		} else {
		
			var senderEmailCheck = "valid";
		
		}
		
		
		
		if(nameField.value == nameField.readAttribute('title')){
			
			var nameError = $('error_name');
			var nameCheck = "invalid";
			nameError.update("enter a valide name");
			//animate error message
			if(nameError.getStyle('display') == 'none'){
			new Effect.BlindDown(nameError, {duration: 0.5});
			} else if(nameError.getStyle('display') != 'none'){
				
				Effect.Shake('error_name', { duration: .7, distance: 4 });
			}
		
		} else {
		
			var nameCheck = "valid";
		
		}
		
		if(emailField.strip().empty()){
			
			var errorElement = $('error_email');
			
				errorElement.update("please add an email address");
				//animate error message
				if(errorElement.getStyle('display') == 'none'){
				new Effect.BlindDown(errorElement, {duration: 0.5});
				} else if(errorElement.getStyle('display') != 'none'){
					Effect.Shake('error_email', { duration: .7, distance: 4 });
				}

		
		} else {
		
			var emailsCheck = "valid";
		
		}
		
		//wrap up validation & send form information
		if(emailsCheck && nameCheck && senderEmailCheck == 'valid'){
			var catVal = ', ';
			$$('.emailToPost').each(function(item) {
											 
				if(item != $$('.emailToPost').last()){
					//$('emailField').insert(item.innerHTML + catVal);
					$('emailField').value = $('emailField').value + item.innerHTML + catVal;
				}else{
					var recip = item.innerHTML;
					$('emailField').value = $('emailField').value + item.innerHTML;
					//your finished, send the email
					
					//disable send btn
					$('sendBtn').stopObserving('click', validateForm);
					
					
				/*new Effect.Morph('sendBtn', {
					style: {
					background: '#A3BA3C'
					}, // CSS Properties
					duration: 0.8 // Core Effect properties
				});

					
					//show the progress bar 
					$('progressBar').appear();
					
			*/
					
					sendMail();
				}
		    
			});

			////capture all the $$('.emailToPost').innerHTML and add them to $('emailField')
			
		} else {
			
			//this form is invalid -- error messages are already being shown
		}

	}
	
	//make an ajax request to send the email
	function sendMail(){
		
		$('emailVid').request({
			onComplete: function(transport) {
				//alert(transport.responseText);
				
				$('tab1').setStyle({height: $('tab1').getHeight()+'px'});
				$('emailForm').fade({duration: 0.5, queue: { position: 'end', scope: 'thanks' }});
				new Effect.Morph('tab1', {
					style: {
					height: ($('thankYou').getHeight()+15) +'px'
					}, // CSS Properties
					duration: 0.5, // Core Effect properties
					queue: { position: 'end', scope: 'thanks' }
				});

				$('thankYou').appear({duration: 0.5, queue: { position: 'end', scope: 'thanks' }});
			}
   	
		});
		
	}
	
	
	
	
	function deleteEmail(event){
	
	elementClick = Event.element(event);
	
	element = $(elementClick).up('div.addedEmail');
	
	
	var hintTxt = $('emailHolder').readAttribute('title');
	var hintContent = "<div id='emailsHint' style='display:none;'>"+hintTxt+"</div>";
	
	//fade out email & then remove it after so the box doesn't register an external click
	new Effect.BlindUp(element, {duration: 0.5, queue: { position: 'end', scope: 'email' }, afterFinish:function(){element.remove(); checkEmptyList();}});
	
	
		function checkEmptyList(){
			
			if($('emailHolder').innerHTML.strip().empty()){
				
				$('emailHolder').setStyle({display:'none'});
			
			///bring in red error message
			
				var errorElement = $('error_email');
				errorElement.update("please add an email address");
				//animate error message
				new Effect.BlindDown(errorElement, {duration: 0.5, queue: { position: 'end', scope: 'email' }});
				
			}
			
		}
		
	}
	
	function clearVal(event){
		
		element = Event.element(event);
		
		if(element.value == element.readAttribute('title')){
			
			element.clear();
		}
	
	}
	
	function setVal(event){
		element = Event.element(event);
		elVal = element.value.strip();
		
		if(elVal.empty()){
			element.value = element.readAttribute('title');
		} 
	}
		
	function swapTabs(event){
		
		event.stop();
		element = Event.element(event);
		elementDiv = Event.element(event).up('div');
		
		if(!element.hasClassName('selected')){
			
			$$(".tab").each(function(el){
				el.removeClassName('selected');
			});
			
			$$(".tabWrap").each(function(el){
				el.removeClassName('selected');
			});
			
			element.addClassName('selected');
			elementDiv.addClassName('selected');
			
			//switch tab content here
			$$(".tabContent").each(function(el){
				el.hide();
			});
			
			var newContentDiv =  $(element.href.split("#")[1]);
			
			newContentDiv.show();
		}
	}
	
	function CheckEmail(email) {
		//email = document.f1.Email.value
		AtPos = email.indexOf("@");
		LastPosAt = email.lastIndexOf("@");
		StopPos = email.lastIndexOf(".");
		Message = "";
		
		if (email == "") {
		Message = "not a valid Email address" + "\n"
		}
		
		if (AtPos == -1 || StopPos == -1) {
		Message = "not a valid email address";
		}
		
		if (StopPos < AtPos) {
		Message = "not a valid email address";
		}
		
		if (StopPos - AtPos == 1) {
		Message = "not a valid email address";
		}
		
		if (AtPos != LastPosAt){
		Message = "please enter one email at a time";
		}
		
		return Message
}



/*---------------------------------------------------------- Universal Functions --------------------------------------------------*/
//copy to clipboard function
function copy(inElement) {
  if (inElement.createTextRange) {
    var range = inElement.createTextRange();
    if (range && BodyLoaded==1)
      range.execCommand('Copy');
  } else {
    var flashcopier = 'flashcopier';
    if(!document.getElementById(flashcopier)) {
      var divholder = document.createElement('div');
      divholder.id = flashcopier;
      document.body.appendChild(divholder);
    }
    document.getElementById(flashcopier).innerHTML = '';
    var divinfo = '<embed src="/assets/swf/_clipboard.swf" FlashVars="clipboard='+encodeURIComponent(inElement.value)+'" width="0" height="0" type="application/x-shockwave-flash"></embed>';
    document.getElementById(flashcopier).innerHTML = divinfo;
  }
}

/*-----------------------------------------------------Transitions Excerpts transistions.js ---------------------------*/

// SwingTo (adapted from "BackEaseOut")
Effect.Transitions.SwingTo = function(pos) {
    var s = 1.70158;
    return (pos-=1)*pos*((s+1)*pos + s) + 1;
};

// Effect.Transitions.easing.js
//==============================================================================
// Robert Penner's easing functions v2.0 (http://www.robertpenner.com/easing)
// Ported to Scriptaculous 1.8 by Riccardo De Agostini (lozioric AT gmail.com)
//
// Original terms of use (http://www.robertpenner.com/easing_terms_of_use.html)
// also apply to this modification.
//==============================================================================
//
// Penner's functions take a minimum of four parameters named t, b, c and d,
// plus, in some cases, optional customization parameters (for details, see
// http://www.robertpenner.com/easing/penner_chapter7_tweening.pdf)
//
// Scriptaculous' transitions are a simplified case of Penner's functions,
// where b is always 0, c is always 1, and d is always 1. I've thus simplified
// the original ActionScript code.
// I've also added some transformation functions, which can take an easeIn, an
// easeOut or an easeIn / easeOut pair and turn them into a complete set of
// transition functions. This obviously introduces some overhead, but greatly
// simplifies the code.
//
// Simple usage example:
//
//    new Effect.Move(myElement, {
//        transition: Effect.Transitions.Cubic.easeInOut
//    });
//
// Customization parameters, where present, may be used as follows:
//
//    // No customization (use Penner's default value)
//    new Effect.Move(myElement, {
//        transition: Effect.Transitions.Back.easeIn
//    });
//
//    // Customized easing
//    new Effect.Move(myElement, {
//        transition: Effect.Transitions.Back.easeIn.custom(2.5)
//    });
//
//==============================================================================
// Changelog:
// 2009-04-24 Initial release
// 2009-04-27 Corrected Sine functions, thanks to advice from Henry on Google's
//             prototype-scriptaculous group
//            Added pre-computed HALF_PI and TWO_PI (also thanks to Henry)
//==============================================================================

Object.extend(Effect.Transitions, (function() {

    //----------------------------------------------------------------------
    // Function transformations
    //----------------------------------------------------------------------

    // easeIn to easeOut and vice versa
    function reverse(eq, t)
    {
        return 1 - eq(1 - t);
    }

    // easeIn to easeInOut
    function easeInToEaseInOut(easeIn, t)
    {
        t = 2 * t;
        return 0.5 * (t < 1 ? easeIn(t) : 2 - easeIn(2 - t));
    }

    // easeOut to easeInOut
    function easeOutToEaseInOut(easeOut, t)
    {
        t = 2 * t;
        return 0.5 * (t < 1 ? 1 - easeOut(1 - t) : 1 + easeOut(t - 1));
    }

    // easeIn / easeOut pair to easeInOut
    function easeInOutPairToEaseInOut(easeIn, easeOut, t)
    {
        t = 2 * t;
        return 0.5 * (t < 1 ? easeIn(t) : 1 + easeOut(t - 1));
    }

    //----------------------------------------------------------------------
    // Function set builders
    //----------------------------------------------------------------------

    // Build a function set from a complete set of easing functions
    function functionSet(easeIn, easeOut, easeInOut)
    {
        return {
            easeIn   : easeIn,
            easeOut  : easeOut,
            easeInOut: easeInOut
        };
    }

    // Build a complete function set from just an easeIn
    function functionSetFromEaseIn(easeIn)
    {
        return {
            easeIn   : easeIn,
            easeOut  : reverse.curry(easeIn),
            easeInOut: easeInToEaseInOut.curry(easeIn)
        };
    }

    // Build a complete function set from just an easeOut
    function functionSetFromEaseOut(easeOut)
    {
        return {
            easeIn   : reverse.curry(easeOut),
            easeOut  : easeOut,
            easeInOut: easeOutToEaseInOut.curry(easeOut)
        };
    }

    // Build a complete function set from an easeIn / easeOut pair
    function functionSetFromEaseInOutPair(easeIn, easeOut)
    {
        return {
            easeIn   : easeIn,
            easeOut  : easeOut,
            easeInOut: easeInOutPairToEaseInOut.curry(easeIn, easeOut)
        };
    }

    // Build a complete function set from just an easeIn,
    // where the given function has custom parameters
    function customizableFunctionSetFromEaseIn()
    {
        var args = $A(arguments);
        var easeIn = args.shift();

        function customEaseIn()
        {
            var args = [0].concat($A(arguments));

            return function(t)
            {
                args[0] = t;
                return easeIn.apply(this, args);
            };
        }

        function customEaseOut()
        {
            return reverse.curry(customEaseIn.apply(this, arguments));
        }

        function customEaseInOut()
        {
            return easeInToEaseInOut.curry(customEaseIn.apply(this, arguments));
        }

        var myEaseIn = customEaseIn.apply(this, args);
        myEaseIn.custom = customEaseIn;
        var myEaseOut = reverse.curry(myEaseIn);
        myEaseOut.custom = customEaseOut;
        var myEaseInOut = easeInToEaseInOut.curry(myEaseIn);
        myEaseInOut.custom = customEaseInOut;

        return {
            easeIn   : myEaseIn,
            easeOut  : myEaseOut,
            easeInOut: myEaseInOut
        };
    }

    //----------------------------------------------------------------------
    // Useful pre-computed values
    //----------------------------------------------------------------------

    var HALF_PI = Math.PI / 2;
    var TWO_PI  = 2 * Math.PI;

    //----------------------------------------------------------------------
    // Penner's tween equations, simplified for Scriptaculous
    //----------------------------------------------------------------------

    function Quad_easeIn(t)
    {
        return t * t;
    }

    function Cubic_easeIn(t)
    {
        return t * t * t;
    }

    function Quart_easeIn(t)
    {
        return t * t * t * t;
    }

    function Quint_easeIn(t)
    {
        return t * t * t * t * t;
    }

    // This one is not Penner's: it's just a generalized case, for use when
    // i.e. Quad is too "soft" for your tastes but Cubic is too "quick"
    // (in this specific case you could use Pow.custom(2.5) for example)
    function Pow_easeIn(t, p)
    {
        return Math.pow(t, p);
    }

    function Back_easeIn(t, s)
    {
        return t * t * ((s + 1) * t - s);
    }

    // TODO (maybe): customize (customizableize? :-) ) this one
    function Bounce_easeOut(t)
    {
        if (t < (1 / 2.75))
            return 7.5625 * t * t;
        if (t < (2 / 2.75))
            return 7.5625 * (t-= (1.5 / 2.75)) * t + 0.75;
        if (t < (2.5 / 2.75))
            return 7.5625 * (t -= (2.25 / 2.75)) * t + 0.9375;
        return 7.5625 * (t -= (2.625 / 2.75)) * t + 0.984375;
    }

    function Circ_easeIn(t)
    {
        return -1 * (Math.sqrt(1 - t * t) - 1);
    }

    function Circ_easeOut(t)
    {
        t -= 1;
        return Math.sqrt(1 - t * t);
    }

    function Elastic_easeIn(t, a, p)
    {
        if (t == 0) return 0;
        if (t == 1) return 1;
        if (a < 1)
        {
            a = 1;
            var s = p / 4;
        }
        else
        {
            var s = p / TWO_PI * Math.asin(1 / a);
        }
        return -(a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t - s) * TWO_PI / p));
    }

    function Expo_easeIn(t)
    {
        return (t == 0) ? 0 : Math.pow(2, 10 * (t - 1));
    }

    function Expo_easeOut(t)
    {
        return (t == 1) ? 1 : 1 - Math.pow(2, -10 * t);
    }

    function Sine_easeIn(t)
    {
        return Math.cos(t * HALF_PI) + 1;
    }

    function Sine_easeOut(t)
    {
        return Math.sin(t * HALF_PI);
    }

    function Sine_easeInOut(t)
    {
        return -0.5 * (Math.cos(Math.PI * t) - 1);
    }

    //--------------------------------------------------------------------------
    // Build and return the equation sets
    //--------------------------------------------------------------------------

    return {
        Quad   : functionSetFromEaseIn(Quad_easeIn),
        Cubic  : functionSetFromEaseIn(Cubic_easeIn),
        Quart  : functionSetFromEaseIn(Quart_easeIn),
        Quint  : functionSetFromEaseIn(Quint_easeIn),
        Pow    : customizableFunctionSetFromEaseIn(Pow_easeIn, 2), // Defaults to Quad
        Back   : customizableFunctionSetFromEaseIn(Back_easeIn, 1.70158),
        Bounce : functionSetFromEaseOut(Bounce_easeOut),
        Circ   : functionSetFromEaseInOutPair(Circ_easeIn, Circ_easeOut),
        Elastic: customizableFunctionSetFromEaseIn(Elastic_easeIn, 1, 0.3),
        Expo   : functionSetFromEaseInOutPair(Expo_easeIn, Expo_easeOut),
        Sine   : functionSet(Sine_easeIn, Sine_easeOut, Sine_easeInOut)
    };

})());

// EOF
