/***************************************************************************
 *                            Barracuda Traffic Development Software
 *                              -------------------
 *     begin                : Mon Mar 23 2006
 *     copyright            : (C) 2006 BoonEx Group
 *     website              : http://www.boonex.com
 *
 *     
 *
 ****************************************************************************/

/***************************************************************************
 *
 *   This is a free software; you can modify it under the terms of BoonEx 
 *   Product License Agreement published on BoonEx site at http://www.boonex.com/downloads/license.pdf
 *   You may not however distribute it for free or/and a fee. 
 *   This notice may not be removed from the source code. You may not also remove any other visible 
 *   reference and links to BoonEx Group as provided in source code.
 *
 ***************************************************************************/

var realSrc='';
var imgs = document.getElementsByTagName('img');

function changePNGImages()
{
	var supported = /MSIE/.test(navigator.userAgent) && !/opera/.test(navigator.userAgent) && navigator.platform == "Win32";
	if ( supported )
	{
		for (var i = 0; i < imgs.length; i++)
		{
			realSrc = imgs[i].src;
			if ( /\.png$/.test( realSrc.toLowerCase()) ) fixImage(imgs[i]);
		}
	}
}

function fixImage(element) {
   // get src
	var src = element.src;   
	var height = element.height;
	var width = element.width;

	// set blank image
	element.src = blankSrc;
	// moi modifikatsii
	element.style.width = width;
	element.style.height = height;
	// set filter
	element.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" +
								 realSrc + "',sizingMethod='scale')";
}