本文整理汇总了Java中com.actionbarsherlock.internal.nineoldandroids.animation.Keyframe.ObjectKeyframe类的典型用法代码示例。如果您正苦于以下问题:Java ObjectKeyframe类的具体用法?Java ObjectKeyframe怎么用?Java ObjectKeyframe使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ObjectKeyframe类属于com.actionbarsherlock.internal.nineoldandroids.animation.Keyframe包,在下文中一共展示了ObjectKeyframe类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: ofObject
import com.actionbarsherlock.internal.nineoldandroids.animation.Keyframe.ObjectKeyframe; //导入依赖的package包/类
public static KeyframeSet ofObject(Object... values) {
int numKeyframes = values.length;
ObjectKeyframe keyframes[] = new ObjectKeyframe[Math.max(numKeyframes,2)];
if (numKeyframes == 1) {
keyframes[0] = (ObjectKeyframe) Keyframe.ofObject(0f);
keyframes[1] = (ObjectKeyframe) Keyframe.ofObject(1f, values[0]);
} else {
keyframes[0] = (ObjectKeyframe) Keyframe.ofObject(0f, values[0]);
for (int i = 1; i < numKeyframes; ++i) {
keyframes[i] = (ObjectKeyframe) Keyframe.ofObject((float) i / (numKeyframes - 1), values[i]);
}
}
return new KeyframeSet(keyframes);
}
示例2: ofObject
import com.actionbarsherlock.internal.nineoldandroids.animation.Keyframe.ObjectKeyframe; //导入依赖的package包/类
public static KeyframeSet ofObject(Object... values) {
int numKeyframes = values.length;
ObjectKeyframe keyframes[] = new ObjectKeyframe[Math.max(numKeyframes, 2)];
if (numKeyframes == 1) {
keyframes[0] = (ObjectKeyframe) Keyframe.ofObject(0f);
keyframes[1] = (ObjectKeyframe) Keyframe.ofObject(1f, values[0]);
} else {
keyframes[0] = (ObjectKeyframe) Keyframe.ofObject(0f, values[0]);
for (int i = 1; i < numKeyframes; ++i) {
keyframes[i] = (ObjectKeyframe) Keyframe.ofObject((float) i / (numKeyframes - 1), values[i]);
}
}
return new KeyframeSet(keyframes);
}