diff options
author | Scott González <scott.gonzalez@gmail.com> | 2013-05-16 08:34:04 -0400 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2013-05-16 08:34:04 -0400 |
commit | d500e945a46c9e2ce5bbb685661c32b5d3f57d21 (patch) | |
tree | ca7643867ff1a3a08bd1b7393eca71b9a8704a54 | |
parent | 0da5f9946d0a87f3bdd47cf8848fd63956e261d3 (diff) | |
download | jquery-ui-d500e945a46c9e2ce5bbb685661c32b5d3f57d21.tar.gz jquery-ui-d500e945a46c9e2ce5bbb685661c32b5d3f57d21.zip |
Position: Use absolute positioning when getting scrollbar width to avoid reflows of user content. Fixes #9291 - Position - $.position.scrollbarWidth detection causes layout issues.
-rw-r--r-- | ui/jquery.ui.position.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/jquery.ui.position.js b/ui/jquery.ui.position.js index 2d3451c06..d45b24bb1 100644 --- a/ui/jquery.ui.position.js +++ b/ui/jquery.ui.position.js @@ -70,7 +70,7 @@ $.position = { return cachedScrollbarWidth; } var w1, w2, - div = $( "<div style='display:block;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>" ), + div = $( "<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>" ), innerDiv = div.children()[0]; $( "body" ).append( div ); |