fadeIt = false;

function init_fader()
{
    using(window.libs.visualElements);
}

function load_fader(timeout)
{
    if (document.getElementById("fader") && fadeIt)
    {
        //if (!pics) pics = "['files/images/bild1.jpg', 'files/images/bild2.jpg']";
        fadeIt('fader', '"+pics+"', { speed:1400, refreshrate:1, stopTime:3500 });
    }
    else
    {
        if (!timeout) timeout = JS_LIBS["std_timeout"];
        if (timeout > 0)
        {
            timeout = timeout - JS_LIBS["std_interval"];
            setTimeout("load_fader("+timeout+");", JS_LIBS["std_interval"]);
        }
    }
}

//addEvent("initialization", "init_fader();");
//addEvent("load", "load_fader();");

window.onload = function()
{
	if (document.getElementById("minimap"))
	{
		load_miniroutenplaner();
	}
}

window.onunload = function()
{
	if (document.getElementById("minimap"))
	{
		unload_miniroutenplaner();
	}
}
