Closed
Bug 186149
Opened 22 years ago
Closed 21 years ago
[FIXr] scrollIntoView() does not work on dynamically created elements
Categories
(Core :: DOM: Core & HTML, defect, P1)
Core
DOM: Core & HTML
Tracking
()
VERIFIED
FIXED
mozilla1.5alpha
People
(Reporter: bugzilla, Assigned: bzbarsky)
References
Details
(Keywords: testcase)
Attachments
(2 files)
860 bytes,
text/html
|
Details | |
1.92 KB,
patch
|
peterv
:
review+
jst
:
superreview+
asa
:
approval1.4b+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20021217 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3b) Gecko/20021217 Have a container (div) containings several divs, when hardcoded, i can use the scrollIntoView(); to scroll to that element. But when this element is created dynamically, the scrollIntoView() does not work. See attached testcase. Reproducible: Always Steps to Reproduce:
Reporter | ||
Comment 1•22 years ago
|
||
Comment 2•22 years ago
|
||
Not dom events->DOM Html?
Assignee: saari → jst
Component: DOM Events → DOM HTML
QA Contact: vladimire → stummala
Assignee | ||
Comment 4•21 years ago
|
||
The problem (and this affects scrolling to anchors too) is that we can try to scroll before the reflow events have been processed... I suppose I could add the flush to ScrollFrameIntoView itself, but the problem is that reflow can actually trigger frame reconstruction (for example <object> will call CantRenderReplacedElement from reflow!). So we want to call GetPrimaryFrameFor _after_ we flush....
Assignee | ||
Updated•21 years ago
|
Attachment #121584 -
Flags: superreview?(jst)
Attachment #121584 -
Flags: review?(peterv)
Assignee | ||
Comment 5•21 years ago
|
||
Taking.
Comment 6•21 years ago
|
||
Comment on attachment 121584 [details] [diff] [review] Possible patch sr=jst
Attachment #121584 -
Flags: superreview?(jst) → superreview+
Updated•21 years ago
|
Attachment #121584 -
Flags: review?(peterv) → review+
Assignee | ||
Updated•21 years ago
|
Summary: [FIX] scrollIntoView() does not work on dynamically created elements → [FIXr] scrollIntoView() does not work on dynamically created elements
Assignee | ||
Comment 7•21 years ago
|
||
Comment on attachment 121584 [details] [diff] [review] Possible patch Requesting 1.4b approval; this just makes sure that we reflow before we get the coordinates we're going to scroll to....
Attachment #121584 -
Flags: approval1.4b?
Comment 8•21 years ago
|
||
Comment on attachment 121584 [details] [diff] [review] Possible patch a=asa (on behalf of drivers) for checkin to 1.4b
Attachment #121584 -
Flags: approval1.4b? → approval1.4b+
Assignee | ||
Comment 9•21 years ago
|
||
Fixed.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Component: DOM: HTML → DOM: Core & HTML
QA Contact: stummala → general
You need to log in
before you can comment on or make changes to this bug.
Description
•