

Loading…
You don't have to create a new pull request when you change something; if you push your changes to the same branch, your pull request is automatically updated.
Please rebase your changes to the current master branch (or merge the current master branch to yours if that's more comfortable for you) since currently there are conflicts making merge impossible.
Also, please correct your changes according to the style guide: http://contribute.jquery.org/style-guide/js/. I'll have further remarks later.
Thanks!
I am sorry for the code-style problem because my IDE is configed according to my project's code style rules.
As for the new pr, I just want to have a better branch name for you to rebase/merge.
I have rewritten the patch based on current master and jquery code style, please review.
Thanks.
|
This should be in the first line, see:
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
Space after
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
I'm not sure if this case really needs to be separated. @mikesherov, what do you think? (also, space after Actually, I'm quite sure it's not needed, especially that you don't take into account Also, if you remove this condition, the
yiminghe
added a note
relative element with left/top auto needs to return 0px immediately and can not get px value by offsetParent/offsetTop/offsetLeft.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
not
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
We use
to:
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
This adds 5 bytes but prevents
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
use
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
Still: not
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
You're right this is needed... It's a lot of bytes, though, I wonder if there's a shorter way to achieve that.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
|
BTW, since we want
yiminghe
added a note
ok, but it will cause extra code to run at runtime for static case.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
Where are we with this pull request? @yiminghe is it okay? @mikesherov any feedback on the question posed above?
@dmethvin IIRC @mikesherov agreed it's a good fix but don't take my word for it. :)
I had adjust code by request a month ago, it should be ok.
Updated test case: http://jsfiddle.net/QzvH5/15/
We'll wait for 2.1/1.11 with that.
We closed the original ticket wontfix and haven't heard any wailing, so I'll close this.
| @@ -62,7 +62,7 @@ jQuery.support = (function( support ) { | ||
| // Run tests that need a body at doc ready | ||
| jQuery(function() { | ||
| - var container, marginDiv, | ||
| + var container, marginDiv, divStyle, | ||
| // Support: Firefox, Android 2.3 (Prefixed box-sizing versions). | ||
| divReset = "padding:0;margin:0;border:0;display:block;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box", | ||
| body = document.getElementsByTagName("body")[ 0 ]; | ||
| @@ -89,8 +89,9 @@ jQuery.support = (function( support ) { | ||
| // Use window.getComputedStyle because jsdom on node.js will break without it. | ||
| if ( window.getComputedStyle ) { | ||
| - support.pixelPosition = ( window.getComputedStyle( div, null ) || {} ).top !== "1%"; | ||
| - support.boxSizingReliable = ( window.getComputedStyle( div, null ) || { width: "4px" } ).width === "4px"; | ||
| + divStyle = window.getComputedStyle( div, null ) || { width: "4px" }; | ||
|
This adds 5 bytes but prevents
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
|
||
| + support.pixelPosition = divStyle.top !== "1%" && divStyle.left !== "auto"; | ||
| + support.boxSizingReliable = divStyle.width === "4px"; | ||
| // Support: Android 2.3 | ||
| // Check if div with explicit width and no margin-right incorrectly | ||
http://bugs.jquery.com/ticket/13767
tests:
http://jsfiddle.net/yiminghe/Yu9sP/5/