Bug 620259 - add fall through comments to nsTableCellMap::SetNotTopStart and rename to nsTableCellMap::ResetTopStart

r=bernd a=dbaron
This commit is contained in:
timeless@mozdev.org 2011-02-16 14:14:18 +01:00
parent b09ebd34ee
commit b88c6d4720
3 changed files with 15 additions and 13 deletions

View File

@ -925,11 +925,11 @@ void nsTableCellMap::ExpandZeroColSpans()
}
void
nsTableCellMap::SetNotTopStart(PRUint8 aSide,
nsCellMap& aCellMap,
PRUint32 aRowIndex,
PRUint32 aColIndex,
PRBool aIsLowerRight)
nsTableCellMap::ResetTopStart(PRUint8 aSide,
nsCellMap& aCellMap,
PRUint32 aRowIndex,
PRUint32 aColIndex,
PRBool aIsLowerRight)
{
if (!mBCInfo || aIsLowerRight) ABORT0();
@ -939,6 +939,7 @@ nsTableCellMap::SetNotTopStart(PRUint8 aSide,
switch(aSide) {
case NS_SIDE_BOTTOM:
aRowIndex++;
// FALLTHROUGH
case NS_SIDE_TOP:
cellData = (BCCellData*)aCellMap.GetDataAt(aRowIndex, aColIndex);
if (cellData) {
@ -961,6 +962,7 @@ nsTableCellMap::SetNotTopStart(PRUint8 aSide,
break;
case NS_SIDE_RIGHT:
aColIndex++;
// FALLTHROUGH
case NS_SIDE_LEFT:
cellData = (BCCellData*)aCellMap.GetDataAt(aRowIndex, aColIndex);
if (cellData) {

View File

@ -229,11 +229,11 @@ protected:
public:
void ExpandZeroColSpans();
void SetNotTopStart(PRUint8 aSide,
nsCellMap& aCellMap,
PRUint32 aYPos,
PRUint32 aXPos,
PRBool aIsLowerRight = PR_FALSE);
void ResetTopStart(PRUint8 aSide,
nsCellMap& aCellMap,
PRUint32 aYPos,
PRUint32 aXPos,
PRBool aIsLowerRight = PR_FALSE);
void SetBCBorderEdge(mozilla::css::Side aEdge,
nsCellMap& aCellMap,

View File

@ -5903,9 +5903,9 @@ nsTableFrame::CalcBCBorders()
// set the flag on the next border indicating it is not the start of a
// new segment
if (iter.mCellMap) {
tableCellMap->SetNotTopStart(NS_SIDE_BOTTOM, *iter.mCellMap,
info.GetCellEndRowIndex(),
info.GetCellEndColIndex() + 1);
tableCellMap->ResetTopStart(NS_SIDE_BOTTOM, *iter.mCellMap,
info.GetCellEndRowIndex(),
info.GetCellEndColIndex() + 1);
}
}
}