Bug 376662. Make nsIFrame::GetOffsetTo not explicitly use views. r+sr=bzbarsky
This commit is contained in:
@@ -990,7 +990,8 @@ nsGenericElement::GetOffsetRect(nsRect& aRect, nsIContent** aOffsetParent)
|
||||
// It doesn't really matter what we use as aRelativeTo here, since
|
||||
// we only care about the size. Using 'parent' might make things
|
||||
// a bit faster by speeding up the internal GetOffsetTo operations.
|
||||
nsRect rcFrame = nsLayoutUtils::GetAllInFlowRectsUnion(frame, nsnull);
|
||||
nsIFrame* parent = frame->GetParent() ? frame->GetParent() : frame;
|
||||
nsRect rcFrame = nsLayoutUtils::GetAllInFlowRectsUnion(frame, parent);
|
||||
aRect.width = nsPresContext::AppUnitsToIntCSSPixels(rcFrame.width);
|
||||
aRect.height = nsPresContext::AppUnitsToIntCSSPixels(rcFrame.height);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user