$(document).ready(function() {
		
	if($('div.trigger').length > 0) {								
		$('div.trigger').mousedown(function() {
			if ($(this).hasClass('open')) {
				$(this).removeClass('open');
				$(this).addClass('openactive');
				return false;
			} else {
				$(this).removeClass('close');
				$(this).addClass('closeactive');
				return false;
			}			
		});
		$('div.trigger').mouseup(function() {
			if ($(this).hasClass('openactive')) {
				$(this).removeClass('openactive');
				$(this).addClass('close');
				$(this).next().slideDown(100);
				return false;
			} else {
				$(this).removeClass('closeactive');
				$(this).addClass('open');
				$(this).next().slideUp(100);
				return false;
			}			
		});
	}
	
});
