File tree Expand file tree Collapse file tree 1 file changed +1
-28
lines changed Expand file tree Collapse file tree 1 file changed +1
-28
lines changed Original file line number Diff line number Diff line change 27
27
}
28
28
}( function( $ ) {
29
29
( function() {
30
- var cachedScrollbarWidth, supportsOffsetFractions,
30
+ var cachedScrollbarWidth,
31
31
max = Math.max,
32
32
abs = Math.abs,
33
- round = Math.round,
34
33
rhorizontal = /left|center|right/,
35
34
rvertical = /top|center|bottom/,
36
35
roffset = /[\+\-]\d+(\.[\d]+)?%?/,
37
36
rposition = /^\w+/,
38
37
rpercent = /%$/,
39
38
_position = $.fn.position;
40
39
41
- // Support: IE <=9 only
42
- supportsOffsetFractions = function() {
43
- var element = $( "<div>" )
44
- .css( "position", "absolute" )
45
- .appendTo( "body" )
46
- .offset( {
47
- top: 1.5,
48
- left: 1.5
49
- } ),
50
- support = element.offset().top === 1.5;
51
-
52
- element.remove();
53
-
54
- supportsOffsetFractions = function() {
55
- return support;
56
- };
57
-
58
- return support;
59
- };
60
-
61
40
function getOffsets( offsets, width, height ) {
62
41
return [
63
42
parseFloat( offsets[ 0 ] ) * ( rpercent.test( offsets[ 0 ] ) ? width / 100 : 1 ),
@@ -266,12 +245,6 @@ $.fn.position = function( options ) {
266
245
position.left += myOffset[ 0 ];
267
246
position.top += myOffset[ 1 ];
268
247
269
- // If the browser doesn't support fractions, then round for consistent results
270
- if ( !supportsOffsetFractions() ) {
271
- position.left = round( position.left );
272
- position.top = round( position.top );
273
- }
274
-
275
248
collisionPosition = {
276
249
marginLeft: marginLeft,
277
250
marginTop: marginTop
You can’t perform that action at this time.
0 commit comments