Code Duplication    Length = 30-30 lines in 2 locations

resources/lib/jquery-ui/ui/widgets/draggable.js 2 locations

@@ 1163-1192 (lines=30) @@
1160
1161
			first = ( ts || bs || ls || rs );
1162
1163
			if ( o.snapMode !== "outer" ) {
1164
				ts = Math.abs( t - y1 ) <= d;
1165
				bs = Math.abs( b - y2 ) <= d;
1166
				ls = Math.abs( l - x1 ) <= d;
1167
				rs = Math.abs( r - x2 ) <= d;
1168
				if ( ts ) {
1169
					ui.position.top = inst._convertPositionTo( "relative", {
1170
						top: t,
1171
						left: 0
1172
					} ).top;
1173
				}
1174
				if ( bs ) {
1175
					ui.position.top = inst._convertPositionTo( "relative", {
1176
						top: b - inst.helperProportions.height,
1177
						left: 0
1178
					} ).top;
1179
				}
1180
				if ( ls ) {
1181
					ui.position.left = inst._convertPositionTo( "relative", {
1182
						top: 0,
1183
						left: l
1184
					} ).left;
1185
				}
1186
				if ( rs ) {
1187
					ui.position.left = inst._convertPositionTo( "relative", {
1188
						top: 0,
1189
						left: r - inst.helperProportions.width
1190
					} ).left;
1191
				}
1192
			}
1193
1194
			if ( !inst.snapElements[ i ].snapping && ( ts || bs || ls || rs || first ) ) {
1195
				( inst.options.snap.snap &&
@@ 1130-1159 (lines=30) @@
1127
				continue;
1128
			}
1129
1130
			if ( o.snapMode !== "inner" ) {
1131
				ts = Math.abs( t - y2 ) <= d;
1132
				bs = Math.abs( b - y1 ) <= d;
1133
				ls = Math.abs( l - x2 ) <= d;
1134
				rs = Math.abs( r - x1 ) <= d;
1135
				if ( ts ) {
1136
					ui.position.top = inst._convertPositionTo( "relative", {
1137
						top: t - inst.helperProportions.height,
1138
						left: 0
1139
					} ).top;
1140
				}
1141
				if ( bs ) {
1142
					ui.position.top = inst._convertPositionTo( "relative", {
1143
						top: b,
1144
						left: 0
1145
					} ).top;
1146
				}
1147
				if ( ls ) {
1148
					ui.position.left = inst._convertPositionTo( "relative", {
1149
						top: 0,
1150
						left: l - inst.helperProportions.width
1151
					} ).left;
1152
				}
1153
				if ( rs ) {
1154
					ui.position.left = inst._convertPositionTo( "relative", {
1155
						top: 0,
1156
						left: r
1157
					} ).left;
1158
				}
1159
			}
1160
1161
			first = ( ts || bs || ls || rs );
1162