$(document).ready(function(){
	ajuste();
});
$(window).resize(function() {
	ajuste();
});
function ajuste() {
	if (document.body.scrollHeight > parent.document.getElementById("App").offsetHeight) { 
		document.body.style.paddingRight = "0px"; 
	} else { 
		document.body.style.paddingRight = "17px"; 
	} 
} 
function abrir_atalhos(){
	$("#dv_acesso").hide();
	$("#acesso_rapido").removeClass('cl_acesso cl_bt_l_ativo').addClass('cl_acesso cl_bt_l_inativo');

	$("#dv_atalhos").show();
	$("#meus_atalhos").removeClass('cl_atalhos cl_bt_l_inativo').addClass('cl_atalhos cl_bt_l_ativo');
}
function abrir_acesso(){
	$("#dv_acesso").show();
	$("#acesso_rapido").removeClass('cl_acesso cl_bt_l_inativo').addClass('cl_acesso cl_bt_l_ativo');

	$("#dv_atalhos").hide();
	$("#meus_atalhos").removeClass('cl_atalhos cl_bt_l_ativo').addClass('cl_atalhos cl_bt_l_inativo');
}
function busca_opcao(opcao){
	$("#dv_opcoes_busca").removeClass(function() {
	  return $(this).attr('class');
	});
	$("#dv_opcoes_busca").addClass('cl_ativo_op' + opcao);
	$("div[id *= 'dv_con_busca_']").hide();
	$("#dv_con_busca_"+ opcao).show();
}
function noticias_opcao(opcao){
	$("#dv_opcoes_noticias").removeClass(function() {
	  return $(this).attr('class');
	});
	$("#dv_opcoes_noticias").addClass('cl_ativo_op' + opcao);
	$("div[id *= 'dv_con_not_']").hide();
	$("#dv_con_not_"+ opcao).show();
}
function show_tool(opcao){
	$("#info_"+ opcao).fadeIn('fast');
}
function close_tool(){
	$("div[id *= 'info_']").fadeOut('fast');
}
