本文整理汇总了Java中com.nineoldandroids.animation.ValueAnimator.getAnimatedValue方法的典型用法代码示例。如果您正苦于以下问题:Java ValueAnimator.getAnimatedValue方法的具体用法?Java ValueAnimator.getAnimatedValue怎么用?Java ValueAnimator.getAnimatedValue使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.nineoldandroids.animation.ValueAnimator
的用法示例。
在下文中一共展示了ValueAnimator.getAnimatedValue方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
View currentTabView = mTabsContainer.getChildAt(this.mCurrentTab);
IndicatorPoint p = (IndicatorPoint) animation.getAnimatedValue();
mIndicatorRect.left = (int) p.left;
mIndicatorRect.right = (int) p.right;
if (mIndicatorWidth < 0) { //indicatorWidth小于0时,原jpardogo's PagerSlidingTabStrip
} else {//indicatorWidth大于0时,圆角矩形以及三角形
float indicatorLeft = p.left + (currentTabView.getWidth() - mIndicatorWidth) / 2;
mIndicatorRect.left = (int) indicatorLeft;
mIndicatorRect.right = (int) (mIndicatorRect.left + mIndicatorWidth);
}
invalidate();
}
示例2: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
int value = (int) animation.getAnimatedValue();
mArcHeight = value;
if (value == mMaxArcHeight) {
duang();
}
invalidate();
}
示例3: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(final ValueAnimator valueAnimator) {
ContextualUndoView dismissView = mParentAdapter.getViewBeingAnimated();
if (dismissView != null) {
mLayoutParams.height = (Integer) valueAnimator.getAnimatedValue();
dismissView.setLayoutParams(mLayoutParams);
}
}
示例4: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
IndicatorPoint p = (IndicatorPoint) animation.getAnimatedValue();
mIndicatorRect.left = (int) p.left;
mIndicatorRect.right = (int) p.right;
invalidate();
}
示例5: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator valueAnimator) {
// get scale from value animator
float scale = (Float)valueAnimator.getAnimatedValue ();
// record the scale, compare next time
// set correct zoom state
// the first time
if (mOldScaleValue == mTargetMaxScaleValue) {
mScaleState = ScaleState.SCALE_MAX;
} else if (mOldScaleValue > scale) {
if (mScaleState == ScaleState.SCALE_ZOOM_OUT) {
mScaleState = ScaleState.SCALE_MAX;
} else {
mScaleState = ScaleState.SCALE_ZOOM_IN;
}
} else if (mOldScaleValue < scale) {
mScaleState = ScaleState.SCALE_ZOOM_OUT;
}
mOldScaleValue = scale;
// applay the scale matrix
Matrix matrix = new Matrix(mDrawableMatrix);
matrix.postScale(scale, scale, mCenterX, mCenterY);
setImageMatrix(matrix);
}
示例6: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
Float value = (Float) animation.getAnimatedValue();
moveStepperContent(value);
}
示例7: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
mScrollerAlpha = (float) animation.getAnimatedValue();
invalidate();
}
示例8: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(@NonNull final ValueAnimator animation) {
ViewGroup.LayoutParams layoutParams = mView.getLayoutParams();
layoutParams.height = (Integer) animation.getAnimatedValue();
mView.setLayoutParams(layoutParams);
}
示例9: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(final ValueAnimator animation) {
ViewGroup.LayoutParams layoutParams = mView.getLayoutParams();
layoutParams.height = (Integer) animation.getAnimatedValue();
mView.setLayoutParams(layoutParams);
}
示例10: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
currentRadius = (int) animation.getAnimatedValue();
invalidate();
}
示例11: onAnimationUpdate
import com.nineoldandroids.animation.ValueAnimator; //导入方法依赖的package包/类
@Override
public void onAnimationUpdate(ValueAnimator animation) {
PointF pointF = (PointF) animation.getAnimatedValue();
ViewHelper.setX(target,pointF.x);
ViewHelper.setY(target,pointF.y);
ViewHelper.setAlpha(target,1-animation.getAnimatedFraction());
}