Closed Bug 354600 Opened 18 years ago Closed 17 years ago

[FIX]Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set

Categories

(Core :: Layout, defect, P2)

x86
Linux
defect

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(1 file, 3 obsolete files)

I'm getting tired of the MathML whack-a-mole...  Can someone think of a case when a block:

1)  Doesn't have another block as a parent
  and
2)  Shouldn't have NS_BLOCK_SPACE_MGR and NS_BLOCK_MARGIN_ROOT set?

If not, we should just make nsBlockFrame::Init check what the parent is and set the bits if needed, imo.
If the idea works, we should try to do it for Gecko 1.9.  It'd make things a lot less fragile, imo.

Note that blocks already do something like this if they're "box wrapped"; I just think we should change the "parent is a box" test to "parent is not a block".
Flags: blocking1.9?
So I'm tempted to just use IsFloatContainingBlock() to test for block-ness, since that's what the space manager is all about anyway (and because nsBlockFrame happens to be the only thing that is a float containing block).
Attached patch Fix (obsolete) — Splinter Review
I only removed existing flags in places where it was _very_ obvious that the new code would kick in.
Assignee: nobody → bzbarsky
Status: NEW → ASSIGNED
Attachment #245729 - Flags: superreview?(roc)
Attachment #245729 - Flags: review?(roc)
Priority: -- → P2
Summary: Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set → [FIX]Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set
Target Milestone: --- → mozilla1.9alpha
Attachment #245729 - Flags: superreview?(roc)
Attachment #245729 - Flags: superreview+
Attachment #245729 - Flags: review?(roc)
Attachment #245729 - Flags: review+
Hmm. Can an nsColumnSetFrame be put in a non-block parent and cause problems because it doesn't have a space manager?
How so?  The blocks inside the column set all have space managers...
Fixed.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Did this cause bug 361091 ?
Depends on: 361091
Depends on: 361109
Depends on: 361210
I've backed that patch out to fix the regressions; I'll do a patch based on the discussion in bug 361091, but not for a few days.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Summary: [FIX]Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set → Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set
Attached patch Better fix (obsolete) — Splinter Review
That took a few days more than planned.  ;)
Attachment #245729 - Attachment is obsolete: true
Attachment #254125 - Flags: superreview?(roc)
Attachment #254125 - Flags: review?(roc)
Summary: Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set → [FIX]Blocks whose parents are not blocks should have SPACE_MGR and MARGIN_ROOT flags set
Attachment #254125 - Flags: superreview?(roc)
Attachment #254125 - Flags: superreview+
Attachment #254125 - Flags: review?(roc)
Attachment #254125 - Flags: review+
Attached patch Merged to tipSplinter Review
Attachment #254125 - Attachment is obsolete: true
Fixed again.
Status: REOPENED → RESOLVED
Closed: 18 years ago17 years ago
Flags: blocking1.9?
Resolution: --- → FIXED
Depends on: 370933
Attached file xpi files wont install (obsolete) —
Warning: <?xml-stylesheet?> processing instruction does not have any effect outside the prolog anymore (see bug 360119).
Source File: chrome://cbsurgeff/content/firefoxOverlay.xul
Line: 0
Attachment #536114 - Flags: checked-in?
virginiajenn@gmail.com, that attachment seems to have nothing to do with this bug.  Did you mean to attach them to some other bug?
Attachment #536114 - Attachment is obsolete: true
Attachment #536114 - Flags: checked-in?
Product: Core → Core Graveyard
Component: Layout: Misc Code → Layout
Product: Core Graveyard → Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: