Closed Bug 408749 Opened 18 years ago Closed 18 years ago

"ASSERTION: A block's child's next in flow's parent must be a block" with -moz-column, table stuff

Categories

(Core :: Layout, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: jruderman, Assigned: roc)

References

Details

(Keywords: assertion, testcase)

Attachments

(3 files)

Loading the testcase triggers: ###!!! ASSERTION: A block's child's next in flow's parent must be a block!: 'nifBlock->GetType() == nsGkAtoms::blockFrame || nifBlock->GetType() == nsGkAtoms::areaFrame', file /Users/jruderman/trunk/mozilla/layout/generic/nsBlockFrame.cpp, line 3104
Attached file testcase
In this case nifBlock is a table caption frame. Does the assert just need adjusting?
Maybe the assert should use a QueryInterface (or IsFrameOfType)?
Attached patch fix assertSplinter Review
This patch creates nsBlockFrame* nsLayoutUtils::GetAsBlock which wraps QueryInterface. After this I should file a folloup bug to change all kBlockCID QIs to use GetAsBlock ... that'd be a good first bug.
Assignee: nobody → roc
Status: NEW → ASSIGNED
Attachment #293607 - Flags: superreview?(bzbarsky)
Attachment #293607 - Flags: review?(bzbarsky)
OS --> All. (I see this on Linux)
OS: Mac OS X → All
Comment on attachment 293607 [details] [diff] [review] fix assert Looks good. That said, should a caption be splitting like it does in this case?
Attachment #293607 - Flags: superreview?(bzbarsky)
Attachment #293607 - Flags: superreview+
Attachment #293607 - Flags: review?(bzbarsky)
Attachment #293607 - Flags: review+
No. There is no way to reflow a caption continuation. http://mxr.mozilla.org/seamonkey/source/layout/base/nsCSSFrameConstructor.cpp#10423 says "if there's a caption then replicate the caption", but it doesn't, as far as I can tell. I'll post an additional patch to give captions unconstrained height.
Fixes the assertion independently of the other patch.
Attachment #293637 - Flags: superreview?(bzbarsky)
Attachment #293637 - Flags: review?(bzbarsky)
Attachment #293637 - Flags: superreview?(bzbarsky)
Attachment #293637 - Flags: superreview+
Attachment #293637 - Flags: review?(bzbarsky)
Attachment #293637 - Flags: review+
Comment on attachment 293637 [details] [diff] [review] reflow captions with unconstrained height Very safe patch to silence an assertion
Attachment #293637 - Flags: approval1.9?
Attachment #293607 - Flags: approval1.9? → approval1.9+
Attachment #293637 - Flags: approval1.9? → approval1.9+
all checked in, plus the testcase as a crashtest.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: