Skip to main content

Bug Tracker

Side navigation

#5387 closed bug (invalid)

Opened October 16, 2009 01:50AM UTC

Closed December 02, 2010 08:07AM UTC

Last modified March 10, 2012 12:24PM UTC

$(window).scrollLeft() function breaking in IE8 (8.0.6001.18702)

Reported by: dsarosi Owned by: dsarosi
Priority: major Milestone: 1.4
Component: core Version: 1.3.2
Keywords: Cc:
Blocked by: Blocking:
Description

The $(window).scrollLeft() function breaks under the latest update for IE8.

When the dir attribute of the body is set to rtl and the window is minimized, which means that $(window).width() < $(document).width(), the horizontal scrollbar appears. Yet when the scrollbar is on the right, scrollLeft() retunrs 0, while when it's on the left, it returns the difference between window width and document width. This funciton is having an impact jquery draggable, when it's set to autoscroll. When dragging to the left, the scrollbar will scroll to the right, and vice versa.

I was only able to reproduce this issue on that version of IE8. I tried the version on http://spoon.net/browsers which is 8.0.6001.18372. However that version has problems rendering the scrollbar for rtl-minimized pages. Maybe the fix applied to that version breaks the scrollLeft feature.

Attachments (0)
Change History (3)

Changed October 16, 2009 02:57AM UTC by dsarosi comment:1

Sorry, slight correction after I compared the function to other browsers.

In FF3.5 and Opera

When the browser scrollbar is on the right in 'rtl', it returns 0;

When the browser scrollbar is on the left in 'rtl', it returns a negative offset.

In IE6,7,(8.0.6001.18372)

When the browser scrollbar is on the right in 'rtl', it returns a positive offset;

When the browser scrollbar is on the left in 'rtl', it returns 0.

In IE8 (8.0.6001.18702)

When the browser scrollbar is on the right in 'rtl', it returns 0;

When the browser scrollbar is on the left in 'rtl', it returns a positive offset.

Chrome, Safari

This issue cannot be reproduced on webkit as it does not display a horizontal scrollbar at all in 'rtl' mode. https://bugs.webkit.org/show_bug.cgi?id=23556

Changed November 01, 2010 05:50AM UTC by snover comment:2

owner: → dsarosi
status: newpending

I am very confused about what the issue is here. Could you please provide a reduced testcase demonstrating the exact problem you are having? Also, if this is related to a UI Draggable, you should file a ticket in the jQuery UI tracker. Thanks.

Changed December 02, 2010 08:07AM UTC by trac-o-bot comment:3

resolution: → invalid
status: pendingclosed

Automatically closed due to 14 days of inactivity.