rem: BX_dump ("window.setTimeout(BX_source_edit) in BX_source_edit"); 
context: function BX_source_edit(id, selectNodeContents) {    if (BX_range) {        if (!BX_xslViewSource.doc) {            if (!BX_xslViewSource.doc) {                BX_xslViewSource.load(null);            }            //        	BX_xslViewSource.onload = null;  // set the callback when we are done loading			BX_dump ("window.setTimeout(BX_source_edit) in BX_source_edit");			window.setTimeout("BX_source_edit('"+id+"',"+selectNodeContents+")",50);			            return;        }        //		var edit_element = document.getElementById(id).cloneNode(true);        var edit_element = BX_xml.doc.implementation.createDocument("","",null);        edit_element.appendChild(BX_getElementById(id,document).cloneNode(true));        if (edit_element) {            var _new = BX_xml.doc.implementation.createDocument("","",null);            BX_xsltProcessor.transformDocument( edit_element, BX_xslViewSource.doc, _new, null);        } else {            BX_popup_hide();            return;        }        //	BX_clipboard = document.getElementById(id).cloneNode(1);        //	document.getElementById(id).parentNode.removeChild(document.getElementById(id));        //	BX_selection.selectAllChildren(document.getElementById(id));        BX_popup_start("Edit Source ",500,0);        var html = ' <center class="text"><form id="bx_form_clipboard" name="clipboard">';        html += '<input class="buttonklein" type="button" value="Append CDATA" onclick=\'BX_clipboard_insertCDATA()\' />&#160;<br/>';        html += '<textarea name="text" class="clipboardtext" style="margin: 10px;" wrap="virtual" cols="70" rows="28"></textarea>';        html += '<br/><input class="text" type="button" value="update" onclick=\'BX_source_insert("'+id+'",'+selectNodeContents+')\' />';        html += '</form></center>';        BX_popup_addHtml(html);        if(_new.documentElement) {            if (selectNodeContents ) {                childLength = _new.documentElement.childNodes.length                              for (var i = 0; i < childLength; i++) {                                  document.getElementById("bx_form_clipboard" ).text.value += calculateMarkup(_new.documentElement.childNodes[i],true);                              }                          } else {                              document.getElementById("bx_form_clipboard" ).text.value += calculateMarkup(_new.documentElement,true);                          }                      }                      BX_no_events = true;        document.removeEventListener("keypress",BX_keypress,false);        document.removeEventListener("keyup",BX_onkeyup,false);        document.getElementById("bx_form_clipboard" ).text.focus();        BX_popup_show();        //fix for mozilla on mac and windows...    }}
meta: 791	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/791/ffb59be12713348724e09814524fa70b5200d06e/bitfluxeditor_core.js/buggy/src/webapp/lenya/resources/misc/bitflux/bxe/js/bitfluxeditor_core.js