double getAnimatedTop(double percent){ final diff = targetTop - top!; final ratio = diff * percent; return targetTop - (diff - ratio); }