From 2582bfab46613da613f1a3354bc733b68a110b95 Mon Sep 17 00:00:00 2001 From: Scott González Date: Thu, 25 Oct 2012 06:39:14 -0400 Subject: Position: Removed offset option. Fixes #6982 - Position: Remove offset option. --- ui/jquery.ui.position.js | 36 ------------------------------------ 1 file changed, 36 deletions(-) (limited to 'ui/jquery.ui.position.js') diff --git a/ui/jquery.ui.position.js b/ui/jquery.ui.position.js index 5b595a8c0..edbb0f6ff 100644 --- a/ui/jquery.ui.position.js +++ b/ui/jquery.ui.position.js @@ -478,40 +478,4 @@ $.ui.position = { testElementParent.removeChild( testElement ); })(); -// DEPRECATED -if ( $.uiBackCompat !== false ) { - // offset option - (function( $ ) { - var _position = $.fn.position; - $.fn.position = function( options ) { - if ( !options || !options.offset ) { - return _position.call( this, options ); - } - var offset = options.offset.split( " " ), - at = options.at.split( " " ); - if ( offset.length === 1 ) { - offset[ 1 ] = offset[ 0 ]; - } - if ( /^\d/.test( offset[ 0 ] ) ) { - offset[ 0 ] = "+" + offset[ 0 ]; - } - if ( /^\d/.test( offset[ 1 ] ) ) { - offset[ 1 ] = "+" + offset[ 1 ]; - } - if ( at.length === 1 ) { - if ( /left|center|right/.test( at[ 0 ] ) ) { - at[ 1 ] = "center"; - } else { - at[ 1 ] = at[ 0 ]; - at[ 0 ] = "center"; - } - } - return _position.call( this, $.extend( options, { - at: at[ 0 ] + offset[ 0 ] + " " + at[ 1 ] + offset[ 1 ], - offset: undefined - } ) ); - }; - }( jQuery ) ); -} - }( jQuery ) ); -- cgit v1.2.3