Commit 9002196c by resurtm

MSIE fix.

parent 8964d6ec
...@@ -446,12 +446,15 @@ window.onload = function() { ...@@ -446,12 +446,15 @@ window.onload = function() {
}; };
var refreshCallStackItemCode = function(callStackItem) { var refreshCallStackItemCode = function(callStackItem) {
var top = callStackItem.offsetTop - window.scrollY, var top = callStackItem.offsetTop - window.pageYOffset,
lines = Sizzle('pre', callStackItem)[0].getClientRects(), lines = Sizzle('pre', callStackItem)[0].getClientRects(),
lineNumbers = Sizzle('.lines-item', callStackItem), lineNumbers = Sizzle('.lines-item', callStackItem),
errorLine = Sizzle('.error-line', callStackItem)[0], errorLine = Sizzle('.error-line', callStackItem)[0],
hoverLines = Sizzle('.hover-line', callStackItem); hoverLines = Sizzle('.hover-line', callStackItem);
for (var i = 0, imax = lines.length; i < imax; ++i) { for (var i = 0, imax = lines.length; i < imax; ++i) {
if (!lineNumbers[i]) {
continue;
}
lineNumbers[i].style.top = parseInt(lines[i].top - top) + 'px'; lineNumbers[i].style.top = parseInt(lines[i].top - top) + 'px';
hoverLines[i].style.top = parseInt(lines[i].top - top) + 'px'; hoverLines[i].style.top = parseInt(lines[i].top - top) + 'px';
hoverLines[i].style.height = parseInt(lines[i].bottom - lines[i].top) + 'px'; hoverLines[i].style.height = parseInt(lines[i].bottom - lines[i].top) + 'px';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment