/*-----------------------------------------------------------
-------------------------------------------------------------
-------------------------------------------------------------
		COMPORTAMENTI GRAFICI
-------------------------------------------------------------
-------------------------------------------------------------
-----------------------------------------------------------*/
var bottonePermanenteCorrente;

/*-------------------------------
	BUTTON MOUSE OVER
-------------------------------*/
function ButtonMouseOver(tdElement) 
{
	if (currEditorMode == "HTML") return;

	if (tdElement != null) 
	{
		with(tdElement.style) 
		{
			backgroundColor = "#f7f7f7";
			border = "1px solid #cccccc";
			color = "#000000";            
		}
	}
}//ButtonMouseOver
 
/*-------------------------------
	BUTTON MOUSE OUT
-------------------------------*/
function  ButtonMouseOut(tdElement) 
{
	if (currEditorMode == "HTML") return;

	if (tdElement != null) 
	{
		with(tdElement.style) 
		{
			backgroundColor = "e0e0e0";
			border = "1px solid e0e0e0";
			color = "#000000";           
		}
	}
}
 

 /*-------------------------------
	BUTTON GRANDE MOUSE OUT
-------------------------------*/
function  ButtonGrandeMouseOut(tdElement) 
{
	if (currEditorMode == "HTML") return;

	if (tdElement != null) 
	{
		with(tdElement.style) 
		{
			backgroundColor = "#f7f7f7";
			border = "1px solid #f7f7f7";
			color = "#000000";           
		}
	}
}


/*-------------------------------
	CLICCA BOTTONE PERMANENTE
-------------------------------*/
function  CliccaBottonePermanente(tdElement, BottoniPermanenti) 
{
	if (tdElement != null) 
	{
		StileBottonePermanenteSelezionato(tdElement);
		bottonePermanenteCorrente = tdElement.id;

		for (var i=0;i < BottoniPermanenti.length ;i=i+1 )
		{
			if (BottoniPermanenti[i].id != bottonePermanenteCorrente) 
					StileBottonePermanenteNonSelezionato(BottoniPermanenti[i]);
		}
	}
}//CliccaBottonePermanente


/*-------------------------------------------
	STILE BOTTONE PERMANENTE SELEZIONATO
-------------------------------------------*/
function  StileBottonePermanenteSelezionato(tdElement) 
{
	if (tdElement != null) 
	{
		if (tdElement.id == bottonePermanenteCorrente) return;

		tdElement.style.backgroundColor = "#F1EFE2";
		tdElement.style.border = "1px solid #B3C6BB";
		tdElement.style.color = "#000000";            
	}
}//StileBottonePermanenteSelezionato


/*-------------------------------------------
	STILE BOTTONE PERMANENTE NON SELEZIONATO
-------------------------------------------*/
function  StileBottonePermanenteNonSelezionato(tdElement) 
{
	if (tdElement != null) 
	{
		if (tdElement.id == bottonePermanenteCorrente) return;

		tdElement.style.backgroundColor = "#f7f7f7";
		tdElement.style.border = "1px solid #f7f7f7";
		tdElement.style.color = "#000000";            
	}
}//StileBottonePermanenteSelezionato


/*-------------------------------
	RIGA MOUSE OVER
-------------------------------*/
function RigaMouseOver(trElement) 
{
	if (currEditorMode == "HTML") return;

	if (trElement != null) 
	{
		with(trElement.style) 
		{
			backgroundColor = "#F7F7F7";
		}
	}
}//ButtonMouseOver
 
/*-------------------------------
	RIGA MOUSE OUT
-------------------------------*/
function  RigaMouseOut(tdElement) 
{
	if (currEditorMode == "HTML") return;

	if (tdElement != null) 
	{
		with(tdElement.style) 
		{
			backgroundColor = "#FFFFFF";
		}
	}
}
