Bug 1171419 part 2 - Remove useless aPresContext param from RenumberLists. r=xidorn

This commit is contained in:
Mats Palmgren 2016-09-01 17:36:22 +02:00
Родитель caa4e63ee5
Коммит 6e54c147d1
3 изменённых файлов: 9 добавлений и 11 удалений

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

@ -674,7 +674,7 @@ nsBlockFrame::GetMinISize(nsRenderingContext *aRenderingContext)
curFrame->LazyMarkLinesDirty();
}
if (RenumberLists(PresContext())) {
if (RenumberLists()) {
AddStateBits(NS_FRAME_HAS_DIRTY_CHILDREN);
}
if (GetStateBits() & NS_BLOCK_NEEDS_BIDI_RESOLUTION)
@ -762,7 +762,7 @@ nsBlockFrame::GetPrefISize(nsRenderingContext *aRenderingContext)
curFrame->LazyMarkLinesDirty();
}
if (RenumberLists(PresContext())) {
if (RenumberLists()) {
AddStateBits(NS_FRAME_HAS_DIRTY_CHILDREN);
}
if (GetStateBits() & NS_BLOCK_NEEDS_BIDI_RESOLUTION)
@ -1108,7 +1108,7 @@ nsBlockFrame::Reflow(nsPresContext* aPresContext,
if (GetStateBits() & NS_BLOCK_NEEDS_BIDI_RESOLUTION)
static_cast<nsBlockFrame*>(FirstContinuation())->ResolveBidi();
if (RenumberLists(aPresContext)) {
if (RenumberLists()) {
AddStateBits(NS_FRAME_HAS_DIRTY_CHILDREN);
}
@ -2932,11 +2932,10 @@ nsBlockFrame::AttributeChanged(int32_t aNameSpaceID,
if (nsGkAtoms::start == aAttribute ||
(nsGkAtoms::reversed == aAttribute &&
mContent->IsHTMLElement(nsGkAtoms::ol))) {
nsPresContext* presContext = PresContext();
// XXX Not sure if this is necessary anymore
if (RenumberLists(presContext)) {
presContext->PresShell()->
if (RenumberLists()) {
PresContext()->PresShell()->
FrameNeedsReflow(this, nsIPresShell::eStyleChange,
NS_FRAME_HAS_DIRTY_CHILDREN);
}
@ -2953,10 +2952,9 @@ nsBlockFrame::AttributeChanged(int32_t aNameSpaceID,
// Tell the enclosing block frame to renumber list items within
// itself
if (nullptr != blockParent) {
nsPresContext* presContext = PresContext();
// XXX Not sure if this is necessary anymore
if (blockParent->RenumberLists(presContext)) {
presContext->PresShell()->
if (blockParent->RenumberLists()) {
PresContext()->PresShell()->
FrameNeedsReflow(blockParent, nsIPresShell::eStyleChange,
NS_FRAME_HAS_DIRTY_CHILDREN);
}

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

@ -789,7 +789,7 @@ protected:
// NS_FRAME_HAS_DIRTY_CHILDREN bit set on it by the caller; either directly
// if it's already in reflow, or via calling FrameNeedsReflow() to schedule a
// reflow.
bool RenumberLists(nsPresContext* aPresContext);
bool RenumberLists();
void ReflowBullet(nsIFrame* aBulletFrame,
BlockReflowInput& aState,

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

@ -1814,7 +1814,7 @@ nsContainerFrame::FrameStartsCounterScope(nsIFrame* aFrame)
}
bool
nsBlockFrame::RenumberLists(nsPresContext* aPresContext)
nsBlockFrame::RenumberLists()
{
if (!nsContainerFrame::FrameStartsCounterScope(this)) {
// If this frame doesn't start a counter scope then we don't need