mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
Stronger band-aid to prevent table splitting inside columns bug 362275 r/sr=roc
This commit is contained in:
parent
99fc87fa1c
commit
97b5794242
@ -431,6 +431,7 @@ nsColumnSetFrame::ReflowChildren(nsHTMLReflowMetrics& aDesiredSize,
|
||||
availSize, availSize.width,
|
||||
aReflowState.mComputedHeight);
|
||||
kidReflowState.mFlags.mIsTopOfPage = PR_TRUE;
|
||||
kidReflowState.mFlags.mTableIsSplittable = PR_FALSE;
|
||||
|
||||
#ifdef DEBUG_roc
|
||||
printf("*** Reflowing child #%d %p: availHeight=%d\n",
|
||||
|
@ -100,6 +100,7 @@ nsHTMLReflowState::nsHTMLReflowState(nsPresContext* aPresContext,
|
||||
mLineLayout = nsnull;
|
||||
mFlags.mSpecialHeightReflow = PR_FALSE;
|
||||
mFlags.mIsTopOfPage = PR_FALSE;
|
||||
mFlags.mTableIsSplittable = PR_FALSE;
|
||||
mFlags.mNextInFlowUntouched = PR_FALSE;
|
||||
mFlags.mAssumingHScrollbar = mFlags.mAssumingVScrollbar = PR_FALSE;
|
||||
mFlags.mHasClearance = PR_FALSE;
|
||||
|
@ -318,6 +318,8 @@ struct nsHTMLReflowState : public nsCSSOffsetState {
|
||||
// (potentially) in a context where
|
||||
// percent heights have a different
|
||||
// basis?
|
||||
PRUint16 mTableIsSplittable:1; // tables are splittable, this should happen only inside a page
|
||||
// and never insider a column frame
|
||||
} mFlags;
|
||||
|
||||
#ifdef IBMBIDI
|
||||
|
@ -147,6 +147,7 @@ NS_IMETHODIMP nsPageFrame::Reflow(nsPresContext* aPresContext,
|
||||
|
||||
nsHTMLReflowState kidReflowState(aPresContext, aReflowState, frame, maxSize);
|
||||
kidReflowState.mFlags.mIsTopOfPage = PR_TRUE;
|
||||
kidReflowState.mFlags.mTableIsSplittable = PR_TRUE;
|
||||
|
||||
// calc location of frame
|
||||
nscoord xc = mPD->mReflowMargin.left + mPD->mExtraMargin.left;
|
||||
|
@ -1286,7 +1286,7 @@ nsTableRowGroupFrame::Reflow(nsPresContext* aPresContext,
|
||||
|
||||
// See if all the frames fit. Do not try to split anything if we're
|
||||
// not paginated ... we can't split across columns yet.
|
||||
if (aPresContext->IsPaginated() &&
|
||||
if (aReflowState.mFlags.mTableIsSplittable &&
|
||||
(NS_FRAME_NOT_COMPLETE == aStatus || splitDueToPageBreak ||
|
||||
aDesiredSize.height > aReflowState.availableHeight)) {
|
||||
// Nope, find a place to split the row group
|
||||
|
Loading…
Reference in New Issue
Block a user