Eliminated FindCellLayoutData() and changed code to use GetCellLayoutData()

instead


git-svn-id: svn://10.0.0.236/trunk@3662 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
troy 1998-06-11 18:50:17 +00:00
parent 40b11809ed
commit c1f731addb
4 changed files with 4 additions and 54 deletions

View File

@ -321,30 +321,6 @@ void nsTableFrame::ListColumnLayoutData(FILE* out, PRInt32 aIndent) const
}
}
/**
* Find the CellLayoutData assocated with the TableCell
**/
nsCellLayoutData* nsTableFrame::FindCellLayoutData(nsTableCell* aCell)
{
if (aCell != nsnull)
{
if (nsnull!=mColumnLayoutData)
{
PRInt32 numCols = mColumnLayoutData->Count();
for (PRInt32 i = 0; i<numCols; i++)
{
nsColLayoutData *colLayoutData = (nsColLayoutData *)(mColumnLayoutData->ElementAt(i));
PRInt32 index = colLayoutData->IndexOf(aCell);
if (index != -1)
return colLayoutData->ElementAt(index);
}
}
}
return nsnull;
}
/**
* For the TableCell in CellData, find the CellLayoutData assocated
* and add it to the list
@ -354,7 +330,7 @@ void nsTableFrame::AppendLayoutData(nsVoidArray* aList, nsTableCell* aTableCell)
if (aTableCell != nsnull)
{
nsCellLayoutData* layoutData = FindCellLayoutData(aTableCell);
nsCellLayoutData* layoutData = GetCellLayoutData(aTableCell);
if (layoutData != nsnull)
aList->AppendElement((void*)layoutData);
}
@ -530,7 +506,7 @@ void nsTableFrame::RecalcLayoutData()
r++;
}
nsCellLayoutData* cellLayoutData = FindCellLayoutData(cell);
nsCellLayoutData* cellLayoutData = GetCellLayoutData(cell);
if (cellLayoutData != nsnull)
cellLayoutData->RecalcLayoutData(this,boundaryCells);
}

View File

@ -167,7 +167,6 @@ public:
* Calculate Layout Information
*
*/
nsCellLayoutData* FindCellLayoutData(nsTableCell* aCell);
void AppendLayoutData(nsVoidArray* aList, nsTableCell* aTableCell);
void RecalcLayoutData();
void ResetCellLayoutData( nsTableCell* aCell,

View File

@ -321,30 +321,6 @@ void nsTableFrame::ListColumnLayoutData(FILE* out, PRInt32 aIndent) const
}
}
/**
* Find the CellLayoutData assocated with the TableCell
**/
nsCellLayoutData* nsTableFrame::FindCellLayoutData(nsTableCell* aCell)
{
if (aCell != nsnull)
{
if (nsnull!=mColumnLayoutData)
{
PRInt32 numCols = mColumnLayoutData->Count();
for (PRInt32 i = 0; i<numCols; i++)
{
nsColLayoutData *colLayoutData = (nsColLayoutData *)(mColumnLayoutData->ElementAt(i));
PRInt32 index = colLayoutData->IndexOf(aCell);
if (index != -1)
return colLayoutData->ElementAt(index);
}
}
}
return nsnull;
}
/**
* For the TableCell in CellData, find the CellLayoutData assocated
* and add it to the list
@ -354,7 +330,7 @@ void nsTableFrame::AppendLayoutData(nsVoidArray* aList, nsTableCell* aTableCell)
if (aTableCell != nsnull)
{
nsCellLayoutData* layoutData = FindCellLayoutData(aTableCell);
nsCellLayoutData* layoutData = GetCellLayoutData(aTableCell);
if (layoutData != nsnull)
aList->AppendElement((void*)layoutData);
}
@ -530,7 +506,7 @@ void nsTableFrame::RecalcLayoutData()
r++;
}
nsCellLayoutData* cellLayoutData = FindCellLayoutData(cell);
nsCellLayoutData* cellLayoutData = GetCellLayoutData(cell);
if (cellLayoutData != nsnull)
cellLayoutData->RecalcLayoutData(this,boundaryCells);
}

View File

@ -167,7 +167,6 @@ public:
* Calculate Layout Information
*
*/
nsCellLayoutData* FindCellLayoutData(nsTableCell* aCell);
void AppendLayoutData(nsVoidArray* aList, nsTableCell* aTableCell);
void RecalcLayoutData();
void ResetCellLayoutData( nsTableCell* aCell,