No ticket: Reduce size in anticipation of Sizzle-free builds

(cherry picked from commit dbf3056b25)
This commit is contained in:
Richard Gibson 2013-02-22 16:33:52 -05:00
parent 85ee87b444
commit 9338a69e30
2 changed files with 4 additions and 3 deletions

View File

@ -10,8 +10,9 @@ var
core_strundefined = typeof undefined,
// Use the correct document accordingly with window argument (sandbox)
document = window.document,
location = window.location,
document = window.document,
docElem = document.documentElement,
// Map over jQuery in case of overwrite
_jQuery = window.jQuery,

View File

@ -125,13 +125,13 @@ jQuery.fn.extend({
offsetParent: function() {
return this.map(function() {
var offsetParent = this.offsetParent || document.documentElement;
var offsetParent = this.offsetParent || docElem;
while ( offsetParent && ( !jQuery.nodeName( offsetParent, "html" ) && jQuery.css( offsetParent, "position") === "static" ) ) {
offsetParent = offsetParent.offsetParent;
}
return offsetParent || document.documentElement;
return offsetParent || docElem;
});
}
});