/*


	# -------------------------------------------------------------------------------------------- #
	#																			#
	# main.js																		#
	#																			#
	# MySpinalCord.com																#
	# Copyright 2011 Thommy Morgan													#
	# All Rights Reserved															#
	#																			#
	# -------------------------------------------------------------------------------------------- #


		
	
*/
	
 
 	/*
 	# ----------------------------------------------------------------------------- #
 	# Declare desktop object											 	#
	# ----------------------------------------------------------------------------- #*/
	
	
	var desktop = {

		
		/*
	 	# ----------------------------------------------------------------------------- #
	 	# Loadup														 	#
		# ----------------------------------------------------------------------------- #*/
		
		
		extendedLoadup: function(){},
		
		
		loadup: function() {
	
			DC.anim = $("div#animationLayer");
		
			var searchBars = document.getElementsByClassName("globalSearchBar");
			for(var i = 0; i < searchBars.length; i++)
				new DC.Textfield(searchBars[i]);
		
			$("div#navlink_ask").addEventTo("click", function() { SpinalEngine.formAnim.showAskDialog(); } );

			desktop.extendedLoadup();
			
			document.onkeydown 		= function(e) { checkForScrollEvent(e); };
			document.onmousewheel 	= function(e) { userDidStartScrollEvent(e); };
			
		},
		
		
		/*
	 	# ----------------------------------------------------------------------------- #
	 	# Animaton													 	#
		# ----------------------------------------------------------------------------- #*/
		
		
		show_spine: function(spine) {
			$("spinalGraphicOverlay").setSRC("http://static.myspinalcord.com/Images/desktop/spines/spinalcord" + spine + ".png");
		},
		
	
	}


	onload = desktop.loadup;
	
	
