Skip to content

Commit

Permalink
modified animator detail
Browse files Browse the repository at this point in the history
  • Loading branch information
SilenceDut committed Jun 21, 2016
1 parent 1a2c3ee commit d8f0734
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,9 @@ private void verticalAnimate(final int startHeight, final int endHeight ) {
final View target = getChildAt(1);
mExpandAnimator = ValueAnimator.ofInt(startHeight,endHeight);
mExpandAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
//private IntEvaluator intEvaluator = new IntEvaluator();
int lastHeight=0;
@Override
public void onAnimationUpdate(ValueAnimator animation) {
int height = (int) animation.getAnimatedValue();
int scrollStep = height-lastHeight;
lastHeight=height;
target.getLayoutParams().height=height;
target.getLayoutParams().height= ( int) animation.getAnimatedValue();
target.requestLayout();
}
});
Expand Down

0 comments on commit d8f0734

Please sign in to comment.