Bug 410229. Check in preemptive fix for failing testcases to resolve Linux orange.

This commit is contained in:
roc+@cs.cmu.edu 2008-01-03 20:28:15 -08:00
Родитель 0897e6bcea
Коммит 903f1a020d
2 изменённых файлов: 8 добавлений и 7 удалений

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

@ -753,15 +753,16 @@ static void
SetTextRectangle(const nsRect& aLayoutRect, nsPresContext* aPresContext,
nsTextRectangle* aRect)
{
double scale = 4096.0;
double scale = 65536.0;
// Round to the nearest 1/scale units. We choose scale so it can be represented
// exactly by machine floating point.
double scaleInv = 1/scale;
double t2pScaled = scale/aPresContext->AppUnitsPerCSSPixel();
aRect->SetRect(RoundFloat(aLayoutRect.x*t2pScaled)*scaleInv,
RoundFloat(aLayoutRect.y*t2pScaled)*scaleInv,
RoundFloat(aLayoutRect.width*t2pScaled)*scaleInv,
RoundFloat(aLayoutRect.height*t2pScaled)*scaleInv);
double x = RoundFloat(aLayoutRect.x*t2pScaled)*scaleInv;
double y = RoundFloat(aLayoutRect.y*t2pScaled)*scaleInv;
aRect->SetRect(x, y,
RoundFloat(aLayoutRect.XMost()*t2pScaled)*scaleInv - x,
RoundFloat(aLayoutRect.YMost()*t2pScaled)*scaleInv - y);
}
static PRBool

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

@ -54,11 +54,11 @@ is(s.getBoundingClientRect().bottom, rects[2].bottom,
s = document.getElementById("s2");
inner = document.getElementById("inner2");
rects = s.getClientRects();
todo_is(s.getBoundingClientRect().bottom, inner.getBoundingClientRect().bottom,
is(s.getBoundingClientRect().bottom, inner.getBoundingClientRect().bottom,
"'"+s.id+"' "+"IB-split span should end where its last line ends");
is(s.getClientRects().length, 3,
"'"+s.id+"' "+"IB-split span should have three CSS boxes");
todo_is(s.getBoundingClientRect().bottom, rects[2].bottom,
is(s.getBoundingClientRect().bottom, rects[2].bottom,
"'"+s.id+"' "+"IB-split span should end where its last rect ends");
s = document.getElementById("s3");