[Webkit-unassigned] [Bug 121876] New: Starting at r154614, setting the document scroll position isn't symmetric; can successfully set document.body.scrollTop, but can only read from document.documentElement.scrollTop
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Sep 24 15:55:59 PDT 2013
https://bugs.webkit.org/show_bug.cgi?id=121876
Summary: Starting at r154614, setting the document scroll
position isn't symmetric; can successfully set
document.body.scrollTop, but can only read from
document.documentElement.scrollTop
Product: WebKit
Version: 528+ (Nightly build)
Platform: Unspecified
OS/Version: Unspecified
Status: UNCONFIRMED
Severity: Normal
Priority: P2
Component: New Bugs
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: rmondello at apple.com
CC: darin at apple.com, bdakin at apple.com, gur.trio at gmail.com
Using a WebKit nighty or a ToT build, load a page whose height is sufficient for playing around with scrollTop in Web Inspector, like http://www.w3.org/html/wg/drafts/html/master/
After r154614, `document.body.scrollTop = 400;` will scroll the document, but turning around to read from `document.body.scrollTop` always returns 0. Reading `document.documentElement.scrollTop` gives the document's actual scroll offset at any given time, but setting it with `document.documentElement.scrollTop = 800;`does nothing.
This asymmetry doesn't seem right. Whether it's document.body.scrollTop or document.documentElement.scrollTop which actually sets and gets the document's scrollTop, it should be symmetric.
For reference:
IE10 can read/write document.documentElement.scrollTop
Firefox 23.0.1 can read/write document.documentElement.scrollTop
Chrome (27.0.1453.93) can read/write document.body.scrollTop
Safari (6.0.5) can read/write document.body.scrollTop
WebKit ToT (after r154614):
document.body.scrollTop = 400; // works
document.body.scrollTop; // always returns 0
document.documentElement.scrollTop; // works for reading the value
document.documentElement.scrollTop = 500; // doesn't do anything
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list