function VbottomPanel(container){
this.container = container;
this.id='VbottomPanel';
this.HidePanel=function(){if(e('tableForBottomPanel').style.display=='none'){e('tableForBottomPanel').style.display='';}else{e('tableForBottomPanel').style.display='none';}}

this.systemStatus=function(text){
e('sistemMessage').innerHTML=text.substr(0, 70);
e('sistemMessage').setAttribute('title', text);
}
this.creatPanel=function(container) {
this.MainTable=document.createElement("table");
var m=this.MainTable;
m.id='tableForBottomPanel'
m.width='100%';
m.style.cellSpacing='0';
m.cellSpacing='0';
m.insertRow(0);
m.rows[0].insertCell(0);
m.rows[0].insertCell(1);
m.rows[0].insertCell(2);

this.BackButton=new buttonOK(m.rows[0].cells[0]);
this.BackButton.Name='<img src="/img/button/left.gif" style="margin-top: 5px;" border="0" />';
this.BackButton.attributeSet('href', 'http://www.vi-tel.ru');
this.BackButton.attributeSet('style.margin', '6px');
this.BackButton.attributeSet('style.bottom', '0px');
this.BackButton.attributeSet('style.left', '0px');
this.BackButton.attributeSet('style.position', 'absolute');
this.BackButton.attributeSet('id', 'HideButton');
this.BackButton.CreateButton();


m.rows[0].cells[0].height='66px';
m.rows[0].cells[0].width='25%';
m.rows[0].cells[1].width='50%';
m.rows[0].cells[2].width='25%';
m.rows[0].cells[1].style.verticalAlign='bottom'; 
m.rows[0].cells[1].style.textAlign='center'; 
m.rows[0].cells[2].style.textAlign='right';
this.LogoAndCopyright=document.createElement("table");
this.LogoAndCopyright.insertRow(0);
this.LogoAndCopyright.rows[0].insertCell(0);
this.LogoAndCopyright.rows[0].insertCell(1);
this.LogoAndCopyright.rows[0].insertCell(2);
this.Message=document.createElement("div");
if(navigator.appVersion.indexOf('MSIE')!=-1){
m.rows[0].cells[0].style.background='none';
m.rows[0].cells[0].style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\'img/bottom1.png\', sizingMethod=\'scale\')';
m.rows[0].cells[1].style.background='none';
m.rows[0].cells[1].style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\'img/bottom2.png\', sizingMethod=\'scale\')';
m.style.background='none';
m.style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\'img/bottom2.png\', sizingMethod=\'scale\')';
m.rows[0].cells[2].style.background='none';
m.rows[0].cells[2].style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\'img/bottom3.png\', sizingMethod=\'scale\')';

//this.Logo.style.background='none';
//this.Logo.style.filter = 'progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\'img/bottom4.png\', sizingMethod=\'scale\')';
}else{
//m.rows[0].cells[0].style.background='url(/img/bottom1.png) no-repeat 100% 0px;';
m.rows[0].cells[0].style.backgroundImage='url(/img/bottom1.png)';
m.rows[0].cells[0].style.backgroundRepeat='no-repeat';
m.rows[0].cells[0].style.backgroundPosition='bottom right';
//m.rows[0].cells[0].style.backgroundRepeat='';
m.rows[0].cells[1].style.backgroundImage='url(/img/bottom2.png)';
m.rows[0].cells[1].style.backgroundRepeat='repeat-x';
m.rows[0].cells[1].style.backgroundPosition='bottom center';
m.rows[0].cells[2].style.backgroundImage='url(/img/bottom3.png)';
m.rows[0].cells[2].style.backgroundRepeat='no-repeat';
m.rows[0].cells[2].style.backgroundPosition='bottom left';
//this.Logo.style.background='url(img/bottom4.png);';
//this.Logo.style.backgroundRepeat='no-repeat';
}

this.container.appendChild(m);

/*this.HideButton=new buttonOK(e('body'));
this.HideButton.Name='<img src="/img/button/top.gif" style="margin-top: 5px;" />';
this.HideButton.onclick=this.HidePanel;
this.HideButton.attributeSet('style.margin', '5px');
this.HideButton.attributeSet('style.bottom', '0px');
this.HideButton.attributeSet('style.right', '0px');
this.HideButton.attributeSet('style.zIndex', '51');
this.HideButton.attributeSet('style.position', 'absolute');
this.HideButton.attributeSet('id', 'HideButton');
this.HideButton.CreateButton();
*/
this.HideButton = document.createElement("div");
this.HideButton.style.position='absolute';
this.HideButton.style.bottom='5px';
this.HideButton.style.right='0';
this.HideButton.style.zIndex='50';
this.HideButton.innerHTML='<img src="img/topbuttonright.gif" style="margin-right:0px; margin-top:5px;" border=0 />';
e('body').appendChild(this.HideButton);
this.HideButton.onclick=this.HidePanel;





//this.Logo.style.width='115px';
//this.Logo.style.height='20px';
//this.Logo.innerHTML='&nbsp;';
//this.Message.id='sistemMessage';
//this.Message.innerHTML='&nbsp;';

/*this.LogoAndCopyright.rows[0].cells[0].appendChild(this.Logo);
this.LogoAndCopyright.rows[0].cells[0].style.verticalAlign="middle";
this.LogoAndCopyright.rows[0].cells[1].style.color="rgb(255,255,255)";
this.LogoAndCopyright.rows[0].cells[1].style.fontSize="9px";
this.LogoAndCopyright.rows[0].cells[1].style.padding="2px";
this.LogoAndCopyright.rows[0].cells[1].innerHTML='<nobr>Copyright (c) 2007-2008 OOO "VI-TEL".</nobr><br><nobr> All rights reserved.</nobr><br><nobr>Разработка: VI-TEL, дизайн: www.artis.ru</nobr>';
this.LogoAndCopyright.rows[0].cells[2].style.color="rgb(255,255,255)";
this.LogoAndCopyright.rows[0].cells[2].style.fontSize="10px";
this.LogoAndCopyright.rows[0].cells[2].style.borderLeft="#CCCCCC solid 1px";
this.LogoAndCopyright.rows[0].cells[1].style.borderLeft="#CCCCCC solid 1px";
this.LogoAndCopyright.rows[0].cells[2].id='sistemMessage';
this.LogoAndCopyright.rows[0].cells[2].style.verticalAlign="middle";
this.LogoAndCopyright.rows[0].cells[2].innerHTML='&nbsp;';*/
//m.rows[0].cells[1].appendChild(this.LogoAndCopyright);
/*m.rows[0].cells[1].style.verticalAlign="middle";
m.rows[0].cells[1].style.paddingTop="24px";
display3 = new VButtonFrom3Part(m.rows[0].cells[1]);
display3.Name='&nbsp;';
display3.LeftPart='img/blackwindowleft.gif';
display3.FonPart='url(img/blackwindowfon.gif)';
display3.RightPart='img/blackwindowright.gif';
display3.mainId="sistemMessage";
display3.CreateButton();
*/
m.rows[0].cells[1].style.verticalAlign="middle";
m.rows[0].cells[1].style.paddingTop="24px";
display3 = new VButtonFrom3Part(m.rows[0].cells[1]);
display3.Name='<div style="margin-right: 5px;"><img  src="img/0.gif" border="0" style="float: left;" id="loadingBar"/></div><div id="sistemMessage" style="float: left; margin-left: 15px; text-align: center" ></div><div class="nonAction" id="statusBar">&nbsp;</div>';
display3.LeftPart='img/blackwindowleft.gif';
display3.FonPart='url(img/blackwindowfon.gif)';
display3.RightPart='img/blackwindowright.gif';
//display3.mainId="sistemMessage";
display3.CreateButton();
//m.rows[0].cells[1].appendChild(this.Message);
}}

function startLoadBar(){e('loadingBar').src='img/loadingBar2.gif';}
function stopLoadBar(){e('loadingBar').src='img/0.gif';}
function errorStatus(){e('statusBar').className='error';}
function normalStatus(){e('statusBar').className='norm';}
function nonStatus(){e('statusBar').className='nonAction';}
function attentionStatus(){e('statusBar').className='att';}