// JavaScript Document
/* Rollover Menu */
function SimpleSwap(el, which) {
    el.src = el.getAttribute(which || "origsrc");
}
function SimpleSwapSetup() {
    var x = document.getElementsByTagName("img");
    for (var i = 0; i < x.length; i++) {
        var osrc = x[i].getAttribute("osrc");
        if (!osrc) continue;

        // preload image
        // comment the next two lines to disable image pre-loading
        x[i].osrc_img = new Image();
        x[i].osrc_img.src = osrc;
        // set event handlers
        x[i].onmouseover = new Function("SimpleSwap(this,'osrc');");
        x[i].onmouseout = new Function("SimpleSwap(this);");
        // save original src
        x[i].setAttribute("origsrc", x[i].src);
    }
}
/* Collapse Menu */
function toggleMenu(objID) {
    if (!document.getElementById) return;
    var ob = document.getElementById(objID).style;
    ob.display = (ob.display == 'block') ? 'none' : 'block';
}
function addLoadEvent(func) {
    var oldonload = window.onload;
    if (typeof window.onload != 'function') {
        window.onload = func;
    } else {
        window.onload = function() {
            if (oldonload) {
                oldonload();
            }
            func();
        }
    }
}
var PreSimpleSwapOnload = (window.onload) ? window.onload : function() { };
window.onload = function() { PreSimpleSwapOnload(); SimpleSwapSetup(); }
