Bug Tracker

Opened 13 years ago

Closed 12 years ago

#6237 closed bug (invalid)

Setting offset of an object which isn't in DOM failed to take scroll into account

Reported by: AzaToth Owned by:
Priority: undecided Milestone:
Component: offset Version: 1.4.2
Keywords: needsreview Cc:
Blocked by: Blocking:


If having an element out of DOM and we have parent scrolled and is setting offset, the scroll in question isn't taken into account, and the object gets wrong offset.

example: http://jsfiddle.net/NgvTt/2/

Change History (4)

comment:1 Changed 13 years ago by AzaToth

Per http://jsfiddle.net/NgvTt/3/ it looks like that $.curCSS is the general problem.

comment:2 Changed 12 years ago by snover

Milestone: 1.4.3

Resetting milestone to future.

comment:3 Changed 12 years ago by snover

Keywords: needsreview added
Priority: undecided

test case demonstrates that the offset that gets set is pretty funky when an element is detached from the document. I’m not actually sure that this is a bug, since technically there is no document for the offset to be relative to when the element is detached.

comment:4 Changed 12 years ago by john

Resolution: invalid
Status: newclosed

Yeah, agree with snover. There really is no offset if the element isn't actually in the page.

Note: See TracTickets for help on using tickets.