String.prototype.line = function () {
    return this.replace(/\s+$/g,'').replace(/^\s+/g,'').replace(/\s+/g,' ');
}

if (!document.onLoadFunctions) {
	document.onLoadFunctions = new Array();
	window.onload = function () { for (var i=0; document.onLoadFunctions.length>i;i++) document.onLoadFunctions[i](); }
}

document.onLoadFunctions.push ( function () {

	var divs = document.getElementsByTagName ("div");
	for (var di=0; divs.length>di; di++) {
		var div = divs[di];
		if (div.className.search(/Infoscreen/)==-1)
			continue;
		if (!div.style.backgroundImage) continue;
		var match = div.style.backgroundImage.match ('[(][\'"]?([^()]+[^"\'])["\']?[)]');
		if (!match) continue;
		div.preloadImage = new Image();
		div.preloadImage.src = match[1];
	}
});

