/* Prayam JS Behaviour DOM events */
var openProjects = new Array();
var PrayamDOM = {

	// Kill borders around clicked links
	'a' : function(a) {
		a.onfocus = function() { this.blur(); }

		// Show all portfolio functions
		if(a.className == "show_all") {
			a.onclick = function() {

				if(openProjects[a.id]) {

					Effect.SlideUp(a.id + "_all");
					//Effect.BlindUp(a.id + "_all");
					a.innerHTML = $F('lang_home_show_all');

					openProjects[a.id] = false;
				}
				else {

					Effect.SlideDown(a.id + "_all");
					//Effect.BlindDown(a.id + "_all");
					a.innerHTML = $F('lang_home_hide_all');

					openProjects[a.id] = true;
				}
			}
		}
	},

	// Show tooltips for hovered project thumbs
	'div.thumb' : function(div) {

		if($(div.id + '_details')) {
			new Tooltip(div.id, div.id + '_details');
		}
	}
}

/* Runtime */
Behaviour.register(PrayamDOM);
