Remove double scrollTop call

This commit is contained in:
Amir E. Aharoni
2014-01-06 13:30:53 +02:00
parent 2d93a37019
commit d8fc3d4b9e

View File

@@ -155,8 +155,9 @@
$firstTargetRegion = $list.find( '#' + this.regions[0] );
// Scroll to appropriate area
$list.scrollTop( 0 );
$list.scrollTop( $firstTargetRegion.offset().top - $list.offset().top );
$list.scrollTop(
$firstTargetRegion.offset().top - $list.offset().top + $list.scrollTop()
);
// Make the selected region (and it only) active
$( '.regionselector' ).removeClass( 'active' );