function displayAdd3a(width, height, bgColor, file, quality, wmode, clickUrl, ver)
{

if (wmode==0)
	wm = "none";
else if (wmode==1)
	wm = "opaque";
else
	wm = "transparent";
	
if (quality==0)
	q = "HIGH";
else if (quality==1)
	q = "MEDIUM";
else
	q = "LOW";
	
x= 19;

y=10;

var objBaseBn = document.getElementById('h_gfxT');
	
	
var objBnFl = document.createElement("div");
	objBnFl.setAttribute('id','bnFloat');
	objBnFl.style.width = '0px';
	objBnFl.style.height = '0px';
	objBnFl.style.position = 'relative';

objBaseBn.appendChild(objBnFl);

var objBnFlIn = document.createElement("div");
	objBnFlIn.setAttribute('id','bnFloatIn');
	objBnFlIn.style.width = width+'px';
	objBnFlIn.style.height = height+'px';
	objBnFlIn.style.position = 'relative';
	//objBnFlIn.style.left = '370px';
	//objBnFlIn.style.position = 'absolute';

objBnFl.appendChild(objBnFlIn);

var objBnFlIn2 = document.createElement("div");
	objBnFlIn2.setAttribute('id','bnFloatIn2');

objBnFlIn.appendChild(objBnFlIn2);

		var flashvars = {};
		flashvars.v = "1";
		flashvars.clickUrl = clickUrl;
		var params = {};
		params.menu = "false";
		params.wmode = "transparent";
		var attributes = {};
		swfobject.embedSWF("gallery/czas_promocji_2011-03-16-03.swf?v=1", "bnFloatIn2", "260", "260", "8.0.0", false, flashvars, params, attributes);
		
}


// --------- Opis Funkcji
// Aktualizuje pozycje warstwy, domyolnie co 500ms
function moveAdd(x,y) {
if (document.all) {
document.all("bnFloat").style.left = document.body.scrollLeft+x;
document.all("bnFloat").style.top = document.body.scrollTop+y;
}
else {
document.getElementById("bnFloat").style.left = document.body.scrollLeft+x; document.getElementById("bnFloat").style.top = document.body.scrollTop+y;
}
/*setTimeout('moveAdd('+x+','+y+')',50);*/
}


function deleteAdd()
{
	/*
	if(document.all && !document.getElementById)
	{
    	document.getElementById = function(id) {
         return document.all[id];
    }
}
*/
	if (document.all)
	{
		document.all('bnFloat').style.visibility = "hidden";
		document.all('bnFloat').style.display = "none";
	}
	else
	{
		document.getElementById('bnFloat').style.visibility = 'hidden';
		document.getElementById('bnFloat').style.display = 'none'; 
	}
}



function displayAdd3(width, height, bgColor, file, quality, wmode, clickUrl, ver)
{

if (wmode==0)
	wm = "none";
else if (wmode==1)
	wm = "opaque";
else
	wm = "transparent";
	
if (quality==0)
	q = "HIGH";
else if (quality==1)
	q = "MEDIUM";
else
	q = "LOW";
	
x= 19;

y=10;

var objBaseBn = document.getElementById('h_gfxT');
	
var objBnFl = document.createElement("div");
	objBnFl.setAttribute('id','bnFloat');
	objBnFl.style.width = '0px';
	objBnFl.style.height = '0px';
	objBnFl.style.position = 'relative';
	objBnFl.style.zIndex  = 1002;

objBaseBn.appendChild(objBnFl);

var objBnFlIn = document.createElement("div");
	objBnFlIn.setAttribute('id','bnFloatIn');
	objBnFlIn.style.width = width+'px';
	objBnFlIn.style.height = height+'px';
	objBnFlIn.style.position = 'relative';
	//objBnFlIn.style.left = '10px';
	//objBnFlIn.style.position = 'absolute';

objBnFl.appendChild(objBnFlIn);

var objBnFlIn2 = document.createElement("div");
	objBnFlIn2.setAttribute('id','bnFloatIn2');

objBnFlIn.appendChild(objBnFlIn2);



		var flashvars = {};
		flashvars.v = ver;
		flashvars.clickUrl = clickUrl;
		var params = {};
		params.menu = "false";
		params.wmode = "opaque";
		var attributes = {};
		swfobject.embedSWF(file+'?v='+ver, "bnFloatIn", width, height, "8.0.0", false, flashvars, params, attributes);		
		
}


function displayAdd2(x, y, width, height, bgColor, file, quality, wmode, clickUrl, ver)
{

if (wmode==0)
	wm = "none";
else if (wmode==1)
	wm = "opaque";
else
	wm = "transparent";
	
if (quality==0)
	q = "HIGH";
else if (quality==1)
	q = "MEDIUM";
else
	q = "LOW";

if (!x) x= 0;
if (!y) y= 0;
	
var objBaseBn = document.getElementById('h_gfxT');
	
	
var objBnFl = document.createElement("div");
	objBnFl.setAttribute('id','bnFloat2');
	objBnFl.style.width = '0px';
	objBnFl.style.height = '0px';
	objBnFl.style.position = 'absolute';
	objBnFl.style.zIndex = '10000';
	
objBaseBn.appendChild(objBnFl);

var objBnFlIn2 = document.createElement("div");
	objBnFlIn2.setAttribute('id','bnFloatIn2');
	objBnFlIn2.style.position = 'relative';
	//objBnFlIn2.style.left = x+'px'; //210
	//objBnFlIn2.style.top = y+'px';
	objBnFlIn2.style.display = 'block';
	objBnFlIn2.style.width = width+'px';
	objBnFlIn2.style.height = height+'px';
	objBnFlIn2.style.zIndex = 1000;
	//alert(objBnFlIn2.left);
	//pos   = $(this).offset();
	


objBnFl.appendChild(objBnFlIn2);

if (wmode==0)
	wm = "none";
else if (wmode==1)
	wm = "opaque";
else
	wm = "transparent";
/*
var so = new SWFObject(file, "v"+ver, width, height, "8", bgColor);


	
if (clickUrl!="")
	so.addVariable("click", clickUrl);
so.addVariable("v", ver);
so.addParam("menu", "false");
so.addParam("quality", "high");
so.addParam("wmode", wm);
so.write("bnFloatIn");
*/


		var flashvars = {};
		flashvars.v = ver;
		flashvars.clickUrl = clickUrl;
		var params = {};
		params.menu = "false";
		params.wmode = wm;
		var attributes = {};
		swfobject.embedSWF(file+'?v='+ver, "bnFloatIn2", width, height, "8.0.0", false, flashvars, params, attributes);		

	$bn = $("#bnFloat2");
	 
  	pos   = $bn.offset();
    width = $bn.width();
	
	//$('#bnFloat2').css('top', x);
	//$('#bnFloat2').css('left', y);
	
	$bn.css({ "left": (pos.left + width + x) + "px", "top":pos.top+y + "px" });

}




function deleteAdd2()
{
	/*
	if(document.all && !document.getElementById)
	{
    	document.getElementById = function(id) {
         return document.all[id];
    }
}
*/
	if (document.all)
	{
		document.all('bnFloat2').style.visibility = "hidden";
		document.all('bnFloat2').style.display = "none";
	}
	else
	{
		document.getElementById('bnFloat2').style.visibility = 'hidden';
		document.getElementById('bnFloat2').style.display = 'none'; 
	}
}


