var huidigSelect = undefined;
var timeToShow = 1000;

function showUitschuif(id) 
{
	$("#post-" + id).css('display', 'block');
	$("#post-" + id).css('width', '1px');
	$("#post-" + id).css('z-index', '1000');
	$("#post-" + id).animate(
		{
			width: '600px'
		}, timeToShow, function() {
			// Animation complete.
		}
	);
	//$("#post-" + id).show();
}

function hideUitschuif(id)
{
	$("#post-" + id).css('z-index', '1100');
	$("#post-" + id).animate(
		{
			width: '1px'
		}, timeToShow, function() {
			$("#post-" + id).css('display', 'none');
		}
	);	
	//$("#post-" + id).hide();
}

function controllerUitschuif(id)
{
	if (id == huidigSelect)
		return;
		
	if (huidigSelect != undefined)
		hideUitschuif(huidigSelect);
		
	huidigSelect = id;
	showUitschuif(id);
}

function hideHuidigUitschuif()
{
	if (huidigSelect != undefined)
		hideUitschuif(huidigSelect);
	
	huidigSelect = undefined;
}
