Issue #1925 - Rename Corner to LogicalCorner and move it to nsStyleCoord.h.

To avoid confusion with mozilla::css::corner, rename ::Corner to
mozilla::LogicalCorner, and move it to nsStyleCoord.h from the illogical
nsCellMap.h location.
Also, append the LogicalCorner prefix to all the enum values, to match
the surrounding coding style.
This commit is contained in:
Moonchild 2024-08-01 20:09:22 +02:00 committed by roytam1
commit 81f60b575a
4 changed files with 25 additions and 24 deletions

View file

@ -5733,7 +5733,8 @@ nsTableFrame::CalcBCBorders()
}
else {
tlCorner.Update(eLogicalSideIEnd, currentBorder);
tableCellMap->SetBCBorderCorner(eBStartIStart, *iter.mCellMap, 0, 0, colIdx,
tableCellMap->SetBCBorderCorner(eLogicalCornerBStartIStart,
*iter.mCellMap, 0, 0, colIdx,
LogicalSide(tlCorner.ownerSide),
tlCorner.subWidth,
tlCorner.bevel);
@ -5783,7 +5784,7 @@ nsTableFrame::CalcBCBorders()
currentBorder = info.GetIStartEdgeBorder();
BCCornerInfo& tlCorner = (0 == rowB) ? bStartCorners[0] : bEndCorners[0];
tlCorner.Update(eLogicalSideBEnd, currentBorder);
tableCellMap->SetBCBorderCorner(eBStartIStart, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBStartIStart, *iter.mCellMap,
iter.mRowGroupStart, rowB, 0,
LogicalSide(tlCorner.ownerSide),
tlCorner.subWidth,
@ -5822,7 +5823,7 @@ nsTableFrame::CalcBCBorders()
bStartCorners[info.GetCellEndColIndex() + 1] :
bEndCorners[info.GetCellEndColIndex() + 1];
trCorner.Update(eLogicalSideBEnd, currentBorder); // bStart-iEnd
tableCellMap->SetBCBorderCorner(eBStartIEnd, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBStartIEnd, *iter.mCellMap,
iter.mRowGroupStart, rowB,
info.GetCellEndColIndex(),
LogicalSide(trCorner.ownerSide),
@ -5830,7 +5831,7 @@ nsTableFrame::CalcBCBorders()
trCorner.bevel);
BCCornerInfo& brCorner = bEndCorners[info.GetCellEndColIndex() + 1];
brCorner.Set(eLogicalSideBStart, currentBorder); // bEnd-iEnd
tableCellMap->SetBCBorderCorner(eBEndIEnd, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIEnd, *iter.mCellMap,
iter.mRowGroupStart, rowB,
info.GetCellEndColIndex(),
LogicalSide(brCorner.ownerSide),
@ -5899,7 +5900,7 @@ nsTableFrame::CalcBCBorders()
if (info.GetCellEndColIndex() < damageArea.EndCol() &&
rowB >= damageArea.StartRow()) {
if (0 != rowB) {
tableCellMap->SetBCBorderCorner(eBStartIEnd, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBStartIEnd, *iter.mCellMap,
iter.mRowGroupStart, rowB,
info.GetCellEndColIndex(),
LogicalSide(trCorner->ownerSide),
@ -5908,7 +5909,7 @@ nsTableFrame::CalcBCBorders()
}
// store any corners this cell spans together with the aja cell
for (int32_t rX = rowB + 1; rX < rowB + segLength; rX++) {
tableCellMap->SetBCBorderCorner(eBEndIEnd, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIEnd, *iter.mCellMap,
iter.mRowGroupStart, rX,
info.GetCellEndColIndex(),
LogicalSide(trCorner->ownerSide),
@ -5945,7 +5946,7 @@ nsTableFrame::CalcBCBorders()
// update/store the bEnd-iStart & bEnd-IEnd corners
BCCornerInfo& blCorner = bEndCorners[colIdx]; // bEnd-iStart
blCorner.Update(eLogicalSideIEnd, currentBorder);
tableCellMap->SetBCBorderCorner(eBEndIStart, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIStart, *iter.mCellMap,
iter.mRowGroupStart,
info.GetCellEndRowIndex(),
colIdx,
@ -5954,7 +5955,7 @@ nsTableFrame::CalcBCBorders()
BCCornerInfo& brCorner = bEndCorners[colIdx + 1]; // bEnd-iEnd
brCorner.Update(eLogicalSideIStart, currentBorder);
if (info.mNumTableCols == colIdx + 1) { // bEnd-IEnd corner of the table
tableCellMap->SetBCBorderCorner(eBEndIEnd, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIEnd, *iter.mCellMap,
iter.mRowGroupStart,
info.GetCellEndRowIndex(), colIdx,
LogicalSide(brCorner.ownerSide),
@ -6026,7 +6027,7 @@ nsTableFrame::CalcBCBorders()
if (info.GetCellEndRowIndex() < damageArea.EndRow() &&
colIdx >= damageArea.StartCol()) {
if (hitsSpanBelow) {
tableCellMap->SetBCBorderCorner(eBEndIStart, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIStart, *iter.mCellMap,
iter.mRowGroupStart,
info.GetCellEndRowIndex(), colIdx,
LogicalSide(blCorner.ownerSide),
@ -6036,7 +6037,7 @@ nsTableFrame::CalcBCBorders()
for (int32_t c = colIdx + 1; c < colIdx + segLength; c++) {
BCCornerInfo& corner = bEndCorners[c];
corner.Set(eLogicalSideIEnd, currentBorder);
tableCellMap->SetBCBorderCorner(eBEndIStart, *iter.mCellMap,
tableCellMap->SetBCBorderCorner(eLogicalCornerBEndIStart, *iter.mCellMap,
iter.mRowGroupStart,
info.GetCellEndRowIndex(), c,
LogicalSide(corner.ownerSide),