List of usage examples for android.view.animation Animation getStartOffset
public long getStartOffset()
From source file:com.github.shareme.gwsmaterialuikit.library.material.app.ToolbarManager.java
private void animateOut() { ActionMenuView menuView = getMenuView(); int count = menuView == null ? 0 : menuView.getChildCount(); Animation slowestAnimation = null; mAnimations.clear();//from w w w . j a v a2 s.c o m mAnimations.ensureCapacity(count); for (int i = 0; i < count; i++) { View child = menuView.getChildAt(i); Animation anim = mAnimator.getOutAnimation(child, i); mAnimations.add(anim); if (anim != null) if (slowestAnimation == null || slowestAnimation.getStartOffset() + slowestAnimation.getDuration() < anim.getStartOffset() + anim.getDuration()) slowestAnimation = anim; } if (slowestAnimation == null) mOutAnimationEndListener.onAnimationEnd(null); else { slowestAnimation.setAnimationListener(mOutAnimationEndListener); for (int i = 0; i < count; i++) { Animation anim = mAnimations.get(i); if (anim != null) menuView.getChildAt(i).startAnimation(anim); } } mAnimations.clear(); }