
/*****************************************/
/* jQuery ********************************/


jQuery(function ($) {
	$('#basic-modal .launchBTN').click(function (e) {
		$('#basic-modal-content').modal({
			//overflow: 'hidden', // simplemodal_1
			opacity:80,
			autoResize:true,
			overlayClose: true,
			modal:true, // (Boolean:true) User will be unable to interact with the page below the modal or tab away from the dialog.
			onOpen: function (dialog) {
				dialog.overlay.slideDown('1000', function () {
					dialog.data.hide();
					dialog.container.fadeIn('fast', function () {
						dialog.data.fadeIn('fast');
					});
				});
			},
			onClose: function (dialog) {
				dialog.data.fadeOut('fast', function () {
					dialog.container.fadeOut('fast', function () {
						dialog.overlay.slideUp('1000', function () {
							$.modal.close();
						});
					});
				});
			}

		});
		return false;
	});
});

/**************************************************/

// le pasas la clase css y pone el height según el mas alto
/*
<script type="text/javascript">
$(document).ready(function() {
	equalHeight($(".column3"));
});
</script>
*/

function equalHeight(group) {
	tallest = 0;
	group.each(function() {
		//thisHeight = $(this).innerHeight();
		thisHeight = $(this).height();
		if(thisHeight > tallest) {
			tallest = thisHeight;
		}
	});
	group.height(tallest);
}

/**************************************************/

/*
<script type="text/javascript">
$(document).ready(function() {
	equalWidth( "#panel3",".colFix2",".colFit" ); // group , ClassFijo , ClassVariables
});
</script>
*/
function equalWidth( group , ClassFijo , ClassVariables) {
	this.group = group;
	this.ClassFijo = ClassFijo || ".colFix";
	this.ClassVariables = ClassVariables || ".colFit";
	this.inicio();
	$this = this;
	$(window).resize( function(){ 
		$this.inicio()
	});
}
equalWidth.prototype.inicio = function(){
	var anchoWeb = $( this.group ).innerWidth();
	var anchoFix = $( this.group + " " + this.ClassFijo ).innerWidth();
	var resto = anchoWeb - ( (anchoFix + 0) );
	
	variables = $( this.group + " " + this.ClassVariables )
	variables.each(function( ) {
		$(this).css({width: (resto/(variables.length))});
		$(this).css({float: 'right'});
	});
	$(this.ClassFijo).css({float: 'right'});
}

/* jQuery *******************************/
/****************************************/







