/* Global MUSE Javascript Functions
* - Use this file for any functions that might be useful in other scripts.
*/


/*
* addLoadEvent()
* - Adds func passed as parameter to the window.onload event. Do not pass parameter with parens.
* - If there is already a function attached to window.onload, the new function is added to the queue.
*/

function addLoadEvent(func) {
    var oldonload = window.onload;
    if (typeof window.onload != 'function') {
	window.onload = func;
    } else {
	window.onload = function() {
	    oldonload();
	    func();
	}
    }
}
