Bug 71181. Revert attinasi's changes for bug 70730.

This commit is contained in:
waterson%netscape.com 2001-03-07 20:15:35 +00:00
Родитель 50c5c0d0c9
Коммит f5d1d74918
8 изменённых файлов: 24 добавлений и 28 удалений

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);

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

@ -172,8 +172,6 @@ protected:
}
PRBool HaveOutsideBullet() const {
NS_ASSERTION((mState & NS_BLOCK_FRAME_HAS_OUTSIDE_BULLET) ? nsnull!=mBullet : nsnull==mBullet,
"HaveOutsideBullet flag and mBullet are out of synch");
return 0 != (mState & NS_BLOCK_FRAME_HAS_OUTSIDE_BULLET);
}

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);

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

@ -172,8 +172,6 @@ protected:
}
PRBool HaveOutsideBullet() const {
NS_ASSERTION((mState & NS_BLOCK_FRAME_HAS_OUTSIDE_BULLET) ? nsnull!=mBullet : nsnull==mBullet,
"HaveOutsideBullet flag and mBullet are out of synch");
return 0 != (mState & NS_BLOCK_FRAME_HAS_OUTSIDE_BULLET);
}

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);

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

@ -1223,7 +1223,7 @@ nsBlockFrame::Destroy(nsIPresContext* aPresContext)
mAbsoluteContainer.DestroyFrames(this, aPresContext);
// Outside bullets are not in our child-list so check for them here
// and delete them when present.
if (mBullet) {
if (HaveOutsideBullet()) {
mBullet->Destroy(aPresContext);
mBullet = nsnull;
}
@ -2480,7 +2480,7 @@ nsBlockFrame::UpdateBulletPosition(nsBlockReflowState& aState)
const nsStyleList* styleList;
GetStyleData(eStyleStruct_List, (const nsStyleStruct*&) styleList);
if (NS_STYLE_LIST_STYLE_POSITION_INSIDE == styleList->mListStylePosition) {
if (mBullet && HaveOutsideBullet()) {
if (HaveOutsideBullet()) {
// We now have an inside bullet, but used to have an outside
// bullet. Adjust the frame line list
nsLineBox* line = aState.NewLineBox(mBullet, 1, PR_FALSE);
@ -4061,7 +4061,7 @@ nsBlockFrame::ReflowBlockFrame(nsBlockReflowState& aState,
// rare case: an empty first line followed by a second line that
// contains a block (example: <LI>\n<P>... ). This is where
// the second case can happen.
if (mBullet && HaveOutsideBullet() &&
if (HaveOutsideBullet() &&
((aLine == mLines) ||
((0 == mLines->mBounds.height) && (aLine == mLines->mNext)))) {
// Reflow the bullet
@ -4683,7 +4683,7 @@ nsBlockFrame::PlaceLine(nsBlockReflowState& aState,
// case is happening then the worst that will happen is that the
// bullet frame will be reflowed twice.
PRBool addedBullet = PR_FALSE;
if (mBullet && HaveOutsideBullet() && (aLine == mLines) &&
if (HaveOutsideBullet() && (aLine == mLines) &&
(!aLineLayout.IsZeroHeight() || !aLine->mNext)) {
nsHTMLReflowMetrics metrics(nsnull);
ReflowBullet(aState, metrics);