| 5608 | // Executing both pixelPosition & boxSizingReliable tests require only one layout |
| 5609 | // so they're executed at the same time to save the second computation. |
| 5610 | function computePixelPositionAndBoxSizingReliable() { |
| 5611 | div.style.cssText = |
| 5612 | // Support: Firefox<29, Android 2.3 |
| 5613 | // Vendor-prefix box-sizing |
| 5614 | "-webkit-box-sizing:border-box;-moz-box-sizing:border-box;" + |
| 5615 | "box-sizing:border-box;display:block;margin-top:1%;top:1%;" + |
| 5616 | "border:1px;padding:1px;width:4px;position:absolute"; |
| 5617 | div.innerHTML = ""; |
| 5618 | docElem.appendChild( container ); |
| 5619 | |
| 5620 | var divStyle = window.getComputedStyle( div, null ); |
| 5621 | pixelPositionVal = divStyle.top !== "1%"; |
| 5622 | boxSizingReliableVal = divStyle.width === "4px"; |
| 5623 | |
| 5624 | docElem.removeChild( container ); |
| 5625 | } |
| 5626 | |
| 5627 | // Support: node.js jsdom |
| 5628 | // Don't assume that getComputedStyle is a property of the global object |