diff -r 930c1fdd3e9f -r 17721bad21df includes/clientside/firebug/firebug.js --- a/includes/clientside/firebug/firebug.js Fri May 29 20:22:30 2009 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1 +0,0 @@ -if(!("console" in window)||!("firebug" in console)){(function(){window.console={log:function(){logFormatted(arguments,"")},debug:function(){logFormatted(arguments,"debug")},info:function(){logFormatted(arguments,"info")},warn:function(){logFormatted(arguments,"warning")},error:function(){logFormatted(arguments,"error")},assert:function(truth,message){if(!truth){var args=[];for(var i=1;i");for(var i=0;i",'',escapeHTML(name),"",'');appendObject(value,html);html.push("")}html.push("");logRow(html,"dir")},dirxml:function(node){var html=[];appendNode(node,html);logRow(html,"dirxml")},group:function(){logRow(arguments,"group",pushGroup)},groupEnd:function(){logRow(arguments,"",popGroup)},time:function(name){timeMap[name]=(new Date()).getTime()},timeEnd:function(name){if(name in timeMap){var delta=(new Date()).getTime()-timeMap[name];logFormatted([name+":",delta+"ms"]);delete timeMap[name]}},count:function(){this.warn(["count() not supported."])},trace:function(){this.warn(["trace() not supported."])},profile:function(){this.warn(["profile() not supported."])},profileEnd:function(){},clear:function(){consoleBody.innerHTML=""},open:function(){toggleConsole(true)},close:function(){if(frameVisible){toggleConsole()}}};var consoleFrame=null;var consoleBody=null;var commandLine=null;var frameVisible=false;var messageQueue=[];var groupStack=[];var timeMap={};var clPrefix=">>> ";var isFirefox=navigator.userAgent.indexOf("Firefox")!=-1;var isIE=navigator.userAgent.indexOf("MSIE")!=-1;var isOpera=navigator.userAgent.indexOf("Opera")!=-1;var isSafari=navigator.userAgent.indexOf("AppleWebKit")!=-1;function toggleConsole(forceOpen){frameVisible=forceOpen||!frameVisible;if(consoleFrame){consoleFrame.style.visibility=frameVisible?"visible":"hidden"}else{waitForBody()}}function focusCommandLine(){toggleConsole(true);if(commandLine){commandLine.focus()}}function waitForBody(){if(document.body){createFrame()}else{setTimeout(waitForBody,200)}}function createFrame(){if(consoleFrame){return }window.onFirebugReady=function(doc){window.onFirebugReady=null;var toolbar=doc.getElementById("toolbar");toolbar.onmousedown=onSplitterMouseDown;commandLine=doc.getElementById("commandLine");addEvent(commandLine,"keydown",onCommandLineKeyDown);addEvent(doc,isIE||isSafari?"keydown":"keypress",onKeyDown);consoleBody=doc.getElementById("log");layout();flush()};var baseURL=getFirebugURL();consoleFrame=document.createElement("iframe");consoleFrame.setAttribute("src",baseURL+"/firebug.html");consoleFrame.setAttribute("frameBorder","0");consoleFrame.style.visibility=(frameVisible?"visible":"hidden");consoleFrame.style.zIndex="2147483647";consoleFrame.style.position="fixed";consoleFrame.style.width="100%";consoleFrame.style.left="0";consoleFrame.style.bottom="0";consoleFrame.style.height="200px";document.body.appendChild(consoleFrame)}function getFirebugURL(){var scripts=document.getElementsByTagName("script");for(var i=0;i=consoleBody.scrollHeight;if(!handler){handler=writeRow}handler(message,className);if(isScrolledToBottom){consoleBody.scrollTop=consoleBody.scrollHeight-consoleBody.offsetHeight}}function appendRow(row){var container=groupStack.length?groupStack[groupStack.length-1]:consoleBody;container.appendChild(row)}function writeRow(message,className){var row=consoleBody.ownerDocument.createElement("div");row.className="logRow"+(className?" logRow-"+className:"");row.innerHTML=message.join("");appendRow(row)}function pushGroup(message,className){logFormatted(message,className);var groupRow=consoleBody.ownerDocument.createElement("div");groupRow.className="logGroup";var groupRowBox=consoleBody.ownerDocument.createElement("div");groupRowBox.className="logGroupBox";groupRow.appendChild(groupRowBox);appendRow(groupRowBox);groupStack.push(groupRowBox)}function popGroup(){groupStack.pop()}function logFormatted(objects,className){var html=[];var format=objects[0];var objIndex=0;if(typeof (format)!="string"){format="";objIndex=-1}var parts=parseFormat(format);for(var i=0;i":return">";case"&":return"&";case"'":return"'";case'"':return"""}return"?"}return String(value).replace(/[<>&"']/g,replaceChars)}function objectToString(object){try{return object+""}catch(exc){return null}}function appendText(object,html){html.push(escapeHTML(objectToString(object)))}function appendNull(object,html){html.push('',escapeHTML(objectToString(object)),"")}function appendString(object,html){html.push('"',escapeHTML(objectToString(object)),""")}function appendInteger(object,html){html.push('',escapeHTML(objectToString(object)),"")}function appendFloat(object,html){html.push('',escapeHTML(objectToString(object)),"")}function appendFunction(object,html){var reName=/function ?(.*?)\(/;var m=reName.exec(objectToString(object));var name=m?m[1]:"function";html.push('',escapeHTML(name),"()")}function appendObject(object,html){try{if(object==undefined){appendNull("undefined",html)}else{if(object==null){appendNull("null",html)}else{if(typeof object=="string"){appendString(object,html)}else{if(typeof object=="number"){appendInteger(object,html)}else{if(typeof object=="function"){appendFunction(object,html)}else{if(object.nodeType==1){appendSelector(object,html)}else{if(typeof object=="object"){appendObjectFormatted(object,html)}else{appendText(object,html)}}}}}}}}catch(exc){}}function appendObjectFormatted(object,html){var text=objectToString(object);var reObject=/\[object (.*?)\]/;var m=reObject.exec(text);html.push('',m?m[1]:text,"")}function appendSelector(object,html){html.push('');html.push('',escapeHTML(object.nodeName.toLowerCase()),"");if(object.id){html.push('#',escapeHTML(object.id),"")}if(object.className){html.push('.',escapeHTML(object.className),"")}html.push("")}function appendNode(node,html){if(node.nodeType==1){html.push('
','<',node.nodeName.toLowerCase(),"");for(var i=0;i',attr.nodeName.toLowerCase(),'="',escapeHTML(attr.nodeValue),""")}if(node.firstChild){html.push('>
');for(var child=node.firstChild;child;child=child.nextSibling){appendNode(child,html)}html.push('
</',node.nodeName.toLowerCase(),">
")}else{html.push("/>")}}else{if(node.nodeType==3){html.push('
',escapeHTML(node.nodeValue),"
")}}}function addEvent(object,name,handler){if(document.all){object.attachEvent("on"+name,handler)}else{object.addEventListener(name,handler,false)}}function removeEvent(object,name,handler){if(document.all){object.detachEvent("on"+name,handler)}else{object.removeEventListener(name,handler,false)}}function cancelEvent(event){if(document.all){event.cancelBubble=true}else{event.stopPropagation()}}function onError(msg,href,lineNo){var html=[];var lastSlash=href.lastIndexOf("/");var fileName=lastSlash==-1?href:href.substr(lastSlash+1);html.push('',msg,"",'");logRow(html,"error")}function onKeyDown(event){if(event.keyCode==123){toggleConsole()}else{if((event.keyCode==108||event.keyCode==76)&&event.shiftKey&&(event.metaKey||event.ctrlKey)){focusCommandLine()}else{return }}cancelEvent(event)}function onSplitterMouseDown(event){if(isSafari||isOpera){return }addEvent(document,"mousemove",onSplitterMouseMove);addEvent(document,"mouseup",onSplitterMouseUp);for(var i=0;i