var WndRadTelWidth = 600;
var WndRadTelHeight = 430;
var WndRadTelTop = 100;
var WndRadTelLeft = 100;

function updatePos()
{
	if (typeof e == 'undefined') e = window.event;
	if (typeof e.layerX == 'undefined') e.layerX = e.offsetX;
    if (typeof e.layerY == 'undefined') e.layerY = e.offsetY;
   var ev = arguments[0] ? arguments[0] : event;
   if(document.all){
	this.x = e.clientX-20;
	this.y = e.clientY;
   }
   else{
	this.x = 600-20;
	this.y = 100;   
   }
}
function przyszlo(nazwa)
{
   $("details").innerHTML = nazwa;
}
function PageStart(){
	//$("#DivTopMenuElementsSpacer").width(document.documentElement.clientWidth-($("#DivTopMenuBelkaMenu").width()+$("#DivTopMenuBelkaElemnts").width()));
	//alert($("#DivTopMenuElementsSpacer").width());	
}
function LoginStart() {
    
    $("#DivLoginHeader2").css("left", (document.documentElement.clientWidth / 2) - ($("#DivLoginHeader2").width() + 20));
    $("#DivLoginHeader2").css("top", (document.documentElement.clientHeight / 2) - ($("#DivLoginHeader2").height() / 2));

    $("#DivLoginSpacer").css("left", (document.documentElement.clientWidth / 2) - ($("#DivLoginSpacer").width() / 2));
    $("#DivLoginSpacer").css("top", (document.documentElement.clientHeight / 2) - ($("#DivLoginSpacer").height() / 2));

    $("#DivLoginFormatka").css("left", (document.documentElement.clientWidth / 2) + 20);
    $("#DivLoginFormatka").css("top", (document.documentElement.clientHeight / 2) - ($("#DivLoginFormatka").height() / 2));

    $("#DivLoginBottomMenuBelka").css("left", 0);
    $("#DivLoginBottomMenuBelka").css("top", (document.documentElement.clientHeight) - ($("#DivLoginBottomMenuBelka").height()));	
}
//function showDiv(divName)
//{
//   document.onmousemove = updatePos
//   $(divName).style.display = "block";
//}
//function wyliczWysokosc()
//{
//    var nh=document.documentElement.clientHeight - 130;
//    mojsplitter.Resize(mojsplitter.GetWidth,nh);
//}

//function hideDiv(divName)
//{
//   $(divName).style.display = "none";
//}
//// --- Div Functions ---
//function myCookie(){
//	this.nameCookie = '';
//	this.mainSettings = '';
//	this.ttl = 0;
//	this.save = function(){
//		var name = this.nameCookie;
//		var value = this.mainSettings;
//		if (this.ttl) {
//			var date = new Date();
//			date.setTime(date.getTime()+(this.ttl*24*60*60*1000));
//			var expires = '; expires='+date.toGMTString();
//		}
//		else var expires = '';
//		if(document.cookie)document.cookie = name+'='+value+expires+'; path=/';
//		else alert('');
//	}
//	this.read = function(){
//		if(this.nameCookie != ''){
//			var nameEQ = this.nameCookie + '=';
//			var ca = document.cookie.split(';');
//			for(var i=0;i < ca.length;i++) {
//				var c = ca[i];
//				while (c.charAt(0)==' ') c = c.substring(1,c.length);
//				if (c.indexOf(nameEQ) == 0) return( c.substring(nameEQ.length,c.length));
//			}
//			return null;
//		}	
//	}
//}
//function mySettings(myString){
//    this.myObject;
//    var ca = myString.split(',')
//    for(var i=0;i< ca.length;i++)
//    {
//        var c = ca[i]
//        while (c.charAt(0)==' ') c = c.substring(1,c.length); 
//    }
//}
//function startDiv(DivName, DivHandle, DivSource, DivWidth,DivMinimizeWidth, DivXPos, DivYPos)
//{
//   this.flaga = true;
//   this.showDiv = function()
//   {
//      if(DivXPos == "center")
//      {
//         $(DivName).style.left = document.documentElement.clientWidth / 2 - (DivWidth / 2);
//      }
//      if(DivXPos == "left")
//      {
//         $(DivName).style.left = 0;
//      }
//      if(DivXPos == "right")
//      {
//         $(DivName).style.left = document.documentElement.clientWidth - DivWidth;
//      }
//      $(DivName).style.top = DivYPos;
//      $(DivName).style.display = "block"
//      Drag.init($(DivHandle), $(DivName));
//   }
//   this.minimize = function()
//   {
//      if(this.flaga == true)
//      {
//         $(DivHandle).style.width = DivMinimizeWidth;
//         $(DivSource).style.display = "none";
//         this.flaga = false;
//      }
//   }
//   this.maximize = function()
//   {
//      if(this.flaga == false)
//      {
//         $(DivHandle).style.width = DivWidth;
//         $(DivSource).style.display = "block";
//         this.flaga = true;
//      }
//   }
//   this.hideDiv = function()
//   {
//      $(DivName).style.display = "none";
//   }
//}
