[CSS21] magic body element handling not stopped when body element removed

NEW
Unassigned

Status

()

Core
CSS Parsing and Computation
9 years ago
9 years ago

People

(Reporter: dbaron, Unassigned)

Tracking

(Blocks: 1 bug)

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

9 years ago
This is spun off from bug 421469.

We fail the following tests:
http://simon.html5.org/test/css/magic-body/overflow/004.htm
http://simon.html5.org/test/css/magic-body/overflow/004.xht

Actual results: scrollbars present on box and viewport

Expected results: scrollbars present on box, but not on viewport, as in http://simon.html5.org/test/css/magic-body/overflow/004-declarative.xht


It seems like we have problems detecting the dynamic change when a body element is removed.  (Once it's removed, it's harder to test if it *was* the body, since it's no longer the body (i.e., the first <body> element child of the root <html> element).

We probably ought to test what happens to:
 (a) background propagation
 (b) overflow propagation
when:
 (1) the root element is removed or added
 (2) the document's body changes due to insertion or removal of an additional body
element (before or after)
 (3) when the only body element is removed or added


We have some code to handle dynamic changes for background propagation in ApplyRenderingChangeToTree in nsCSSFrameConstructor.cpp .  I'm not sure where any existing code for dynamic changes to overflow propagation is.
(Reporter)

Comment 1

9 years ago
(And note that one way to avoid having to handle dynamic changes is to avoid caching stuff that we don't really need to cache; that might be a possibility here.)
(Reporter)

Updated

9 years ago
OS: Linux → All
Hardware: PC → All
Some of the background stuff will also get fixed in bug 480880.
You need to log in before you can comment on or make changes to this bug.