static void openMenu(ViewGroup viewGroup, int openIndex, AnimatorListenerAdapter endListener) {
List<Animator> animList = new ArrayList<>();
for (int i = viewGroup.getChildCount() - 1; i >= 0; i--) {
if (openIndex == i) {
animList.add(createOpenItemAnimator(viewGroup.getChildAt(i)));
} else {
animList.add(createStayHideItemAnimator(viewGroup.getChildAt(i)));
}
}
AnimatorSet animSet = new AnimatorSet();
animSet.setDuration(ANIM_DURATION);
animSet.setInterpolator(new AnticipateInterpolator());
animSet.playTogether(animList);
animSet.addListener(endListener);
animSet.start();
}
AnimatorUtils.java 文件源码
java
阅读 29
收藏 0
点赞 0
评论 0
项目:AndroidArcMenu
作者:
评论列表
文章目录