X-Git-Url: http://git.asbjorn.it/?a=blobdiff_plain;f=src%2Foffset.js;h=20805de1c7d3b94f76095e8cf2178f7983f2547f;hb=c9899a74ac7b7ddb8663f4aa074c1c05f6514e5a;hp=f59fb9b27caa565d414f4b759de81ecf351ac0e0;hpb=415a0916b54a0dd3123893d67cc9091dd8ebe1d6;p=jquery.git diff --git a/src/offset.js b/src/offset.js index f59fb9b..20805de 100644 --- a/src/offset.js +++ b/src/offset.js @@ -43,7 +43,7 @@ jQuery.fn.offset = function() { // Mozilla and Safari > 2 does not include the border on offset parents // However Mozilla adds the border for table cells - if ( mozilla && /^t[d|h]$/i.test(parent.tagName) || !safari2 ) + if ( mozilla && !/^t[d|h]$/i.test(offsetParent.tagName) || safari && parseInt(version) >= 522 ) border( offsetParent ); // Safari <= 2 doubles body offsets with an absolutely positioned element or parent