document.width/document.height flush layout too late

RESOLVED FIXED in mozilla1.9alpha5

Status

()

Core
DOM: Core & HTML
--
minor
RESOLVED FIXED
11 years ago
11 years ago

People

(Reporter: Eli Friedman, Assigned: Eli Friedman)

Tracking

({testcase})

Trunk
mozilla1.9alpha5
testcase
Points:
---
Bug Flags:
in-testsuite ?

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments, 1 obsolete attachment)

11 years ago
536 bytes, text/html
Details
14.36 KB, patch
roc
: review+
Details | Diff | Splinter Review
(Assignee)

Description

11 years ago
Testcase coming up; the issue is caused by the presshell being retrieved before the layout is flushed.

(Bug discovered through code inspection; I haven't seen anyone try this.)
(Assignee)

Comment 1

11 years ago
Created attachment 265501 [details] [diff] [review]
Patch

Fix + some cleanup. (I'm changing the behavior of the HTML calculation slightly, but I doubt anyone cares what the results are with overflow set on both the root element and the body.)
Assignee: general → sharparrow1
Status: NEW → ASSIGNED
(Assignee)

Comment 2

11 years ago
Comment on attachment 265501 [details] [diff] [review]
Patch

Not sure if you're the right person to ask for review, but you r+ed the last patch to this code.
Attachment #265501 - Flags: review?(jonas)
Comment on attachment 265501 [details] [diff] [review]
Patch

This has too much layout specific stuff for me. Please ask one of the layout guys instead. I can sr though unless the reviewer r/sr it.
Attachment #265501 - Flags: review?(jonas)
(Assignee)

Updated

11 years ago
Attachment #265501 - Flags: review?(roc)
+    nsresult rv = GetViewportSize(&width, &height);
+    *aHeight = height;

Why can't you just do "return GetViewportSize(&width, aHeight);" like you did in the other part of the patch?
(Assignee)

Comment 5

11 years ago
Created attachment 265753 [details] [diff] [review]
Patch v2

With more consistent style.
Attachment #265501 - Attachment is obsolete: true
Attachment #265753 - Flags: review?(roc)
Attachment #265501 - Flags: review?(roc)
Attachment #265753 - Flags: superreview+
Attachment #265753 - Flags: review?(roc)
Attachment #265753 - Flags: review+
It looks like this may have caused Bug 381746

Updated

11 years ago
Depends on: 381746
(Assignee)

Updated

11 years ago
No longer depends on: 381746

Comment 7

11 years ago
(This was checked in at 2007-05-22 20:52.)

Should this be marked fixed?
Flags: in-testsuite?
Target Milestone: --- → mozilla1.9alpha5
(Assignee)

Comment 8

11 years ago
Oh yeah, forgot to mark it.
Status: ASSIGNED → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.