Index: branches/RC/core/kernel/utility/debugger/debugger.js =================================================================== diff -u -r9335 -r9359 --- branches/RC/core/kernel/utility/debugger/debugger.js (.../debugger.js) (revision 9335) +++ branches/RC/core/kernel/utility/debugger/debugger.js (.../debugger.js) (revision 9359) @@ -96,7 +96,7 @@ case 'dbg_ReloadFrame': self.location.reload(); break; - + case 'dbg_ShowDebugger': this.Toggle(); break; @@ -113,14 +113,14 @@ document.body.style.textAlign = 'left'; var $toolbar_content = 'Reload Frame'; - + if (this.ErrorsCount > 0) { $toolbar_content += 'Show Debugger (' + this.ErrorsCount + ' errors)'; } else { $toolbar_content += 'Show Debugger'; } - + if (this.SQLCount > 0) { $toolbar_content += '' + this.SQLCount + ' sqls'; } @@ -257,9 +257,9 @@ function GetWindowHeight() { var currWinHeight; - + // if (document.body.clientHeight) { -// currWinHeight = document.body.clientHeight; +// currWinHeight = document.body.clientHeight; if (window.innerHeight) {//FireFox with correction for status bar at bottom of window currWinHeight = window.innerHeight; @@ -379,23 +379,23 @@ } } var the_debugger = this; - drag_object.onmousedown = function(ev){ + this.AddEvent(drag_object, 'mousedown', function(ev){ ev = ev || window.event; the_debugger.InitialPos = findPos(drag_object); var coords = the_debugger.mouseCoords(ev); - var pos = findPos(this); + var pos = findPos(drag_object); the_debugger.MouseOffset = [coords.x - pos[0], coords.y - pos[1]]; - the_debugger.DragObject = this; - the_debugger.LastDragObject = this; + the_debugger.DragObject = drag_object; + the_debugger.LastDragObject = drag_object; the_debugger.DragObject.style.position = 'absolute'; the_debugger.Options = cur_options; startCallback(drag_object); - } - document.onmousemove = function(ev){ - ev = ev || window.event; - var coords = the_debugger.mouseCoords(ev); + }); + this.AddEvent(document, 'mousemove', function(ev) { // window.status = 'mouse at: '+coords.x+','+coords.y; if(the_debugger.DragObject){ + ev = ev || window.event; + var coords = the_debugger.mouseCoords(ev); if (the_debugger.Options.VerticalDrag) { the_debugger.DragObject.style.top = (coords.y - the_debugger.MouseOffset[1] ) + 'px' // ; } @@ -405,13 +405,13 @@ moveCallback(drag_object, coords) return false; } - } - document.onmouseup = function(ev){ + }); + this.AddEvent(document, 'mouseup', function(ev){ var tmp = the_debugger.DragObject; the_debugger.DragObject = null; if(tmp){ endCallback(tmp); } var pos = findPos(drag_object); - } + }); } \ No newline at end of file