Bug 420254, thunderbird often uses ~10% cpu when idle, r=enn, sr=neil, a=beltzner

This commit is contained in:
Olli.Pettay%helsinki.fi 2008-03-07 13:48:06 +00:00
Родитель 067f4b56e5
Коммит d7f0bc1042
1 изменённых файлов: 13 добавлений и 1 удалений

Просмотреть файл

@ -74,7 +74,19 @@
var position = isLTR ? 4 : -1;
var interval = setInterval(function nextStep() {
try {
var width = stack.boxObject.width >> 2;
var width = stack.boxObject.width;
if (!width) {
// Maybe we've been removed from the document.
var currentNode = stack;
while (currentNode && currentNode != stack.ownerDocument) {
currentNode = currentNode.parentNode;
}
if (!currentNode) {
clearInterval(interval);
return;
}
}
width = width >> 2;
spacer.height = stack.boxObject.height;
spacer.width = width;
spacer.left = width * position;