Opened 10 years ago

Closed 10 years ago

#9859 closed defect (fixed)

scrollIntoView bug in Safari

Reported by: haysmark Owned by: Douglas Hays
Priority: high Milestone: 1.4
Component: Dijit Version: 1.3.2
Keywords: Cc:
Blocked By: Blocking:

Description

See attached test cases, which go in dijit/tests/_base.

In test_scroll_iframe, if you click "Scroll bold into view", the letter B in the iframe should scroll into view. In Safari 4, this fails. It seems that adding border or padding to the body of _insideOfIframe.html (as with the dijitTests css) causes this failure. Adding margin does not seem to do anything.

Attachments (4)

_insideOfIframe.html (463 bytes) - added by haysmark 10 years ago.
Supporting file. Goes in dijit/tests/_base
test_scroll_iframe.html (1.7 KB) - added by haysmark 10 years ago.
Run this from dijit/tests/_base.
9859.patch (473 bytes) - added by haysmark 10 years ago.
Fixes #9859. Safari was adding the body's border and padding in scrollIntoView.
9859.2.patch (10.1 KB) - added by haysmark 10 years ago.
Fixes #9859. Safari was adding the body's border and padding in scrollIntoView. Also fixed a bug with scrollIntoView with the robot and iframes.

Download all attachments as: .zip

Change History (8)

Changed 10 years ago by haysmark

Attachment: _insideOfIframe.html added

Supporting file. Goes in dijit/tests/_base

Changed 10 years ago by haysmark

Attachment: test_scroll_iframe.html added

Run this from dijit/tests/_base.

Changed 10 years ago by haysmark

Attachment: 9859.patch added

Fixes #9859. Safari was adding the body's border and padding in scrollIntoView.

Changed 10 years ago by haysmark

Attachment: 9859.2.patch added

Fixes #9859. Safari was adding the body's border and padding in scrollIntoView. Also fixed a bug with scrollIntoView with the robot and iframes.

comment:1 Changed 10 years ago by Douglas Hays

Priority: normalhigh

comment:2 Changed 10 years ago by Douglas Hays

Status: newassigned

comment:3 Changed 10 years ago by Douglas Hays

(In [20428]) Fixes #10020. References #9859. Fixed several problems related to dojo.position()'s use inside iframes. Fixed several IE-specific problems related to inaccurate position() attributes caused by iframe style. Fixed withDoc to restore _isBodyLtr and to properly set/restore isQuirks. Changed isQuirks definition to only check for "BackCompat?" since other values are for ancient unsupported browsers. Added automated iframe tests to html.html. Removed workaround from dijit's scroll.js that's no longer needed after these fixes. Verified all html.html and test_scroll.html tests pass on all supported browsers. !strict

comment:4 Changed 10 years ago by Douglas Hays

Resolution: fixed
Status: assignedclosed

(In [20440]) Fixes #9859 !strict. Ignore padding on HTML/BODY when scrolling. Added testcase. Removed unsupported browser code paths.

Note: See TracTickets for help on using tickets.