Bug Tracker

Opened 14 years ago

Closed 14 years ago

#4906 closed bug (fixed)

Methods jQuery.fn.scrollLeft and jQuery.fn.scrollTop are slow for window

Reported by: mdevils Owned by: brandon
Priority: minor Milestone: 1.4
Component: offset Version: 1.3.2
Keywords: Cc:
Blocked by: Blocking:


If page is not scrolled, the expression will go through all the variants:

this[0] == window || this[0] == document ?
                    self[ i ? 'pageYOffset' : 'pageXOffset' ]
                    ||   jQuery.boxModel && document.documentElement[ method ] ||
					    document.body[ method ]) :
				this[0][ method ];

If window.pageYOffset or window.pageXOffset are defined, they should be returned for window.

Change History (1)

comment:1 Changed 14 years ago by brandon

Priority: majorminor
Resolution: fixed
Status: newclosed

Thanks for catching this mdevils. :) Fixed in r6451

Note: See TracTickets for help on using tickets.