rem: source.messages.appendChild (obj); 
add: tbody.appendChild (obj); 
context: function addHistory (source, obj){    if (!source.messages)    {        source.messages =            document.createElementNS ("http://www.w3.org/1999/xhtml",                                      "html:table");        source.messages.setAttribute ("class", "chat-view");        source.messages.setAttribute ("cellpadding", "0");        source.messages.setAttribute ("cellspacing", "0");        source.messages.setAttribute ("type", source.TYPE);        source.messages.setAttribute ("width", "100%");                switch (source.TYPE)        {            case "IRCChanUser":            case "IRCUser":                source.messages.setAttribute ("nick", source.nick);                break;            case "IRCNetwork":            case "IRCChannel":            case "IRCClient":                source.messages.setAttribute ("name", source.name);                break;            default:                dd ("** 'source' has INVALID TYPE in addHistory **");                break;        }           }    var needScroll = false;    var w = window.frames[0];        if (client.PRINT_DIRECTION == 1)    {        if ((w.document.height - (w.innerHeight + w.pageYOffset)) <            (w.innerHeight / 3))            needScroll = true;        source.messages.appendChild (obj);    }    else        source.messages.insertBefore (obj, source.messages.firstChild);        if (source.MAX_MESSAGES)    {        if (typeof source.messageCount != "number")            source.messageCount = 1;        else            source.messageCount++;        if (source.messageCount > source.MAX_MESSAGES)            if (client.PRINT_DIRECTION == 1)                source.messages.removeChild (source.messages.firstChild);            else                source.messages.removeChild (source.messages.lastChild);    }    if (needScroll && client.currentObject == source)        w.scrollTo (w.pageXOffset, w.document.height);    }
meta: 8395	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/8395/ee3e25cd866563b5083f4eb42f44f9b25afaeeda/static.js/clean/extensions/irc/xul/content/static.js