Skip to content

Commit

Permalink
Bug 1554499 - Rename PerFrameKey -> PerFrameIndex for most methods r=…
Browse files Browse the repository at this point in the history
…mattwoodrow

This distinguishes better between the overloaded aspect of the PerFrameKey and the
actual mixed value.

Differential Revision: https://phabricator.services.mozilla.com/D37804
  • Loading branch information
Gankra committed Jul 17, 2019
1 parent 2806cf4 commit d501009
Show file tree
Hide file tree
Showing 7 changed files with 92 additions and 89 deletions.
11 changes: 6 additions & 5 deletions layout/generic/TextOverflow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,11 +163,12 @@ class nsDisplayTextOverflowMarker final : public nsPaintedDisplayItem {
}

// Should have the same argument signature as the above ctor
static uint16_t CalculatePerFrameKey(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
nscoord aAscent,
const StyleTextOverflowSide& aStyle,
uint32_t aLineNumber, uint16_t aIndex) {
static uint16_t CalculatePerFrameIndex(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
nscoord aAscent,
const StyleTextOverflowSide& aStyle,
uint32_t aLineNumber,
uint16_t aIndex) {
return (aLineNumber << 1) + aIndex;
}

Expand Down
6 changes: 3 additions & 3 deletions layout/mathml/nsMathMLChar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1726,9 +1726,9 @@ class nsDisplayMathMLCharForeground final : public nsPaintedDisplayItem {
}

// Should have the same argument signature as the above ctor
static uint16_t CalculatePerFrameKey(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, nsMathMLChar* aChar,
uint16_t aIndex, bool aIsSelected) {
static uint16_t CalculatePerFrameIndex(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, nsMathMLChar* aChar,
uint16_t aIndex, bool aIsSelected) {
return aIndex;
}

Expand Down
6 changes: 3 additions & 3 deletions layout/mathml/nsMathMLFrame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -309,9 +309,9 @@ class nsDisplayMathMLBar final : public nsPaintedDisplayItem {
}

// Should have the same argument signature as the above ctor
static uint16_t CalculatePerFrameKey(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
uint16_t aIndex) {
static uint16_t CalculatePerFrameIndex(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
uint16_t aIndex) {
return aIndex;
}

Expand Down
8 changes: 4 additions & 4 deletions layout/mathml/nsMathMLmencloseFrame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -714,10 +714,10 @@ class nsDisplayNotation final : public nsPaintedDisplayItem {
}

// Should have the same argument signature as the above ctor
static uint16_t CalculatePerFrameKey(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
nscoord aThickness,
nsMencloseNotation aType) {
static uint16_t CalculatePerFrameIndex(nsDisplayListBuilder* aBuilder,
nsIFrame* aFrame, const nsRect& aRect,
nscoord aThickness,
nsMencloseNotation aType) {
return aType;
}

Expand Down
8 changes: 4 additions & 4 deletions layout/painting/nsDisplayList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3983,7 +3983,7 @@ nsDisplayBackgroundImage::nsDisplayBackgroundImage(
}

// Should have an identical argument signature to the above ctor
uint16_t nsDisplayBackgroundImage::CalculatePerFrameKey(
uint16_t nsDisplayBackgroundImage::CalculatePerFrameIndex(
nsDisplayListBuilder* aBuilder, nsIFrame* aFrame, const InitData& aInitData,
nsIFrame* aFrameForBounds) {
return aInitData.layer;
Expand Down Expand Up @@ -4806,7 +4806,7 @@ nsDisplayTableBackgroundImage::nsDisplayTableBackgroundImage(
}

// Should have an identical argument signature to the above ctor
uint16_t nsDisplayTableBackgroundImage::CalculatePerFrameKey(
uint16_t nsDisplayTableBackgroundImage::CalculatePerFrameIndex(
nsDisplayListBuilder* aBuilder, nsIFrame* aFrame, const InitData& aData,
nsIFrame* aCellFrame) {
return CalculateTablePerFrameKey(aData.layer,
Expand Down Expand Up @@ -5463,7 +5463,7 @@ nsDisplayCompositorHitTestInfo::nsDisplayCompositorHitTestInfo(
}

// Should have the same argument signature as the above ctor
uint16_t nsDisplayCompositorHitTestInfo::CalculatePerFrameKey(
uint16_t nsDisplayCompositorHitTestInfo::CalculatePerFrameIndex(
nsDisplayListBuilder* aBuilder, nsIFrame* aFrame,
const mozilla::gfx::CompositorHitTestInfo& aHitTestFlags, uint16_t aIndex,
const mozilla::Maybe<nsRect>& aArea) {
Expand All @@ -5482,7 +5482,7 @@ nsDisplayCompositorHitTestInfo::nsDisplayCompositorHitTestInfo(
}

// Should have the same argument signature as the above ctor
uint16_t nsDisplayCompositorHitTestInfo::CalculatePerFrameKey(
uint16_t nsDisplayCompositorHitTestInfo::CalculatePerFrameIndex(
nsDisplayListBuilder* aBuilder, nsIFrame* aFrame,
mozilla::UniquePtr<HitTestInfo>&& aHitTestInfo) {
return 0;
Expand Down
Loading

0 comments on commit d501009

Please sign in to comment.