зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1152049 - Rename GetClippedBoundsUpTo into GetScrollClippedBoundsUpTo. r=tn
--HG-- extra : commitid : 5IM4iKZumy9 extra : rebase_source : d1c935ae3f9f11a5219e55c79ad12283adafeabb
This commit is contained in:
Родитель
22ab8b4d6c
Коммит
1e3c6a4c67
|
@ -5287,7 +5287,7 @@ FrameLayerBuilder::BuildContainerLayerFor(nsDisplayListBuilder* aBuilder,
|
||||||
const DisplayItemScrollClip* containerScrollClip = aParameters.mScrollClip;
|
const DisplayItemScrollClip* containerScrollClip = aParameters.mScrollClip;
|
||||||
|
|
||||||
ContainerLayerParameters scaleParameters;
|
ContainerLayerParameters scaleParameters;
|
||||||
nsRect bounds = aChildren->GetClippedBoundsUpTo(aBuilder, containerScrollClip);
|
nsRect bounds = aChildren->GetScrollClippedBoundsUpTo(aBuilder, containerScrollClip);
|
||||||
nsRect childrenVisible =
|
nsRect childrenVisible =
|
||||||
aContainerItem ? aContainerItem->GetVisibleRectForChildren() :
|
aContainerItem ? aContainerItem->GetVisibleRectForChildren() :
|
||||||
aContainerFrame->GetVisualOverflowRectRelativeToSelf();
|
aContainerFrame->GetVisualOverflowRectRelativeToSelf();
|
||||||
|
|
|
@ -1396,11 +1396,11 @@ nsDisplayList::GetBounds(nsDisplayListBuilder* aBuilder) const {
|
||||||
}
|
}
|
||||||
|
|
||||||
nsRect
|
nsRect
|
||||||
nsDisplayList::GetClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
nsDisplayList::GetScrollClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
||||||
const DisplayItemScrollClip* aIncludeScrollClipsUpTo) const {
|
const DisplayItemScrollClip* aIncludeScrollClipsUpTo) const {
|
||||||
nsRect bounds;
|
nsRect bounds;
|
||||||
for (nsDisplayItem* i = GetBottom(); i != nullptr; i = i->GetAbove()) {
|
for (nsDisplayItem* i = GetBottom(); i != nullptr; i = i->GetAbove()) {
|
||||||
bounds.UnionRect(bounds, i->GetClippedBoundsUpTo(aBuilder, aIncludeScrollClipsUpTo));
|
bounds.UnionRect(bounds, i->GetScrollClippedBoundsUpTo(aBuilder, aIncludeScrollClipsUpTo));
|
||||||
}
|
}
|
||||||
return bounds;
|
return bounds;
|
||||||
}
|
}
|
||||||
|
@ -2187,8 +2187,8 @@ nsDisplayItem::GetClippedBounds(nsDisplayListBuilder* aBuilder)
|
||||||
}
|
}
|
||||||
|
|
||||||
nsRect
|
nsRect
|
||||||
nsDisplayItem::GetClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
nsDisplayItem::GetScrollClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
||||||
const DisplayItemScrollClip* aIncludeScrollClipsUpTo)
|
const DisplayItemScrollClip* aIncludeScrollClipsUpTo)
|
||||||
{
|
{
|
||||||
nsRect r = GetClippedBounds(aBuilder);
|
nsRect r = GetClippedBounds(aBuilder);
|
||||||
for (const DisplayItemScrollClip* sc = mScrollClip;
|
for (const DisplayItemScrollClip* sc = mScrollClip;
|
||||||
|
|
|
@ -1437,8 +1437,8 @@ public:
|
||||||
* The intersection is approximate since rounded corners are not taking into
|
* The intersection is approximate since rounded corners are not taking into
|
||||||
* account.
|
* account.
|
||||||
*/
|
*/
|
||||||
nsRect GetClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
nsRect GetScrollClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
||||||
const DisplayItemScrollClip* aIncludeScrollClipsUpTo);
|
const DisplayItemScrollClip* aIncludeScrollClipsUpTo);
|
||||||
|
|
||||||
nsRect GetBorderRect() {
|
nsRect GetBorderRect() {
|
||||||
return nsRect(ToReferenceFrame(), Frame()->GetSize());
|
return nsRect(ToReferenceFrame(), Frame()->GetSize());
|
||||||
|
@ -2162,8 +2162,11 @@ public:
|
||||||
* The result is not cached.
|
* The result is not cached.
|
||||||
*/
|
*/
|
||||||
nsRect GetBounds(nsDisplayListBuilder* aBuilder) const;
|
nsRect GetBounds(nsDisplayListBuilder* aBuilder) const;
|
||||||
nsRect GetClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
/**
|
||||||
const DisplayItemScrollClip* aIncludeScrollClipsUpTo) const;
|
* Return the union of the scroll clipped bounds of all children.
|
||||||
|
*/
|
||||||
|
nsRect GetScrollClippedBoundsUpTo(nsDisplayListBuilder* aBuilder,
|
||||||
|
const DisplayItemScrollClip* aIncludeScrollClipsUpTo) const;
|
||||||
/**
|
/**
|
||||||
* Find the topmost display item that returns a non-null frame, and return
|
* Find the topmost display item that returns a non-null frame, and return
|
||||||
* the frame.
|
* the frame.
|
||||||
|
@ -3187,7 +3190,7 @@ public:
|
||||||
*/
|
*/
|
||||||
virtual void UpdateBounds(nsDisplayListBuilder* aBuilder) override
|
virtual void UpdateBounds(nsDisplayListBuilder* aBuilder) override
|
||||||
{
|
{
|
||||||
mBounds = mList.GetClippedBoundsUpTo(aBuilder, mScrollClip);
|
mBounds = mList.GetScrollClippedBoundsUpTo(aBuilder, mScrollClip);
|
||||||
// The display list may contain content that's visible outside the visible
|
// The display list may contain content that's visible outside the visible
|
||||||
// rect (i.e. the current dirty rect) passed in when the item was created.
|
// rect (i.e. the current dirty rect) passed in when the item was created.
|
||||||
// This happens when the dirty rect has been restricted to the visual
|
// This happens when the dirty rect has been restricted to the visual
|
||||||
|
|
Загрузка…
Ссылка в новой задаче