Skip to content

Commit

Permalink
remove copy contructor in animation evaluator
Browse files Browse the repository at this point in the history
  • Loading branch information
wenchao authored and wenchao committed Dec 18, 2015
1 parent d5c4206 commit 31f3ba1
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
import android.widget.RelativeLayout.LayoutParams
;

import com.wenchao.cardstack.CardUtils;

public class RelativeLayoutParamsEvaluator implements TypeEvaluator<LayoutParams> {

@Override
public LayoutParams evaluate(float fraction, LayoutParams start,
LayoutParams end) {

LayoutParams result = new LayoutParams(start);
LayoutParams result = CardUtils.cloneParams(start);
result.leftMargin += ((end.leftMargin-start.leftMargin)*fraction);
result.rightMargin += ((end.rightMargin-start.rightMargin)*fraction);
result.topMargin += ((end.topMargin-start.topMargin)*fraction);
Expand Down

0 comments on commit 31f3ba1

Please sign in to comment.