Commit abde719a authored by Imran Hussain's avatar Imran Hussain
Browse files

Fix formatting and add missing ; to cb.js

parent bd6650ab
Loading
Loading
Loading
Loading
Loading
+67 −69
Original line number Diff line number Diff line
/*
 addEvent function from http://www.quirksmode.org/blog/archives/2005/10/_and_the_winner_1.html
 */
function addEvent( obj, type, fn )
{
function addEvent(obj, type, fn) {
    if (obj.addEventListener)
        obj.addEventListener(type, fn, false);
	else if (obj.attachEvent)
	{
    else if (obj.attachEvent) {
        obj["e" + type + fn] = fn;
		obj[type+fn] = function() { obj["e"+type+fn]( window.event ); }
        obj[type + fn] = function () {
            obj["e" + type + fn](window.event);
        };
        obj.attachEvent("on" + type, obj[type + fn]);
    }
}
@@ -44,8 +44,7 @@ function insertBottom(obj) {
    obj.appendChild(d);
}

function initCB()
{
function initCB() {
    // Find all div elements
    var divs = document.getElementsByTagName('div');
    var cbDivs = [];
@@ -81,7 +80,6 @@ function initCB()
    }
}

if(document.getElementById && document.createTextNode)
{
if (document.getElementById && document.createTextNode) {
    addEvent(window, 'load', initCB);
}
 No newline at end of file