Java 类android.support.annotation.AnimatorRes 实例源码
项目:GitHub
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:XERUNG
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:XERUNG
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:FindX
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:RxZhiHu
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:Android-Application-ZJB
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:SuperIndicator
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:material-components-android
文件:MotionSpec.java
/** Inflates an instance of MotionSpec from the given animator resource. */
@Nullable
public static MotionSpec createFromResource(Context context, @AnimatorRes int id) {
try {
Animator animator = AnimatorInflater.loadAnimator(context, id);
if (animator instanceof AnimatorSet) {
AnimatorSet set = (AnimatorSet) animator;
return createSpecFromAnimators(set.getChildAnimations());
} else if (animator != null) {
List<Animator> animators = new ArrayList<>();
animators.add(animator);
return createSpecFromAnimators(animators);
} else {
return null;
}
} catch (Exception e) {
Log.w(TAG, "Can't load animation resource ID #0x" + Integer.toHexString(id), e);
return null;
}
}
项目:XueShiShuo
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:View-Images-and-Animations
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:LefishGuide
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:DdBanner
文件:DdAnimateIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:maketaobao
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:BiliNyan-Android
文件:CircleIndicator.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
checkIndicatorConfig(getContext());
}
项目:material
文件:IndicatorView.java
public void configureIndicator(int indicatorWidth, int indicatorHeight, int indicatorMargin,
@AnimatorRes int animatorId, @AnimatorRes int animatorReverseId,
@DrawableRes int indicatorBackgroundId,
@DrawableRes int indicatorUnselectedBackgroundId) {
mIndicatorWidth = indicatorWidth;
mIndicatorHeight = indicatorHeight;
mIndicatorMargin = indicatorMargin;
mAnimatorResId = animatorId;
mAnimatorReverseResId = animatorReverseId;
mIndicatorBackgroundResId = indicatorBackgroundId;
mIndicatorUnselectedBackgroundResId = indicatorUnselectedBackgroundId;
}
项目:material-components-android
文件:FabTransformationSheetBehavior.java
@Override
protected FabTransformationSpec onCreateMotionSpec(Context context, boolean expanded) {
@AnimatorRes int specRes;
if (expanded) {
specRes = R.animator.mtrl_fab_transformation_sheet_expand_spec;
} else {
specRes = R.animator.mtrl_fab_transformation_sheet_collapse_spec;
}
FabTransformationSpec spec = new FabTransformationSpec();
spec.timings = MotionSpec.createFromResource(context, specRes);
spec.positioning = new Positioning(Gravity.CENTER, 0f, 0f);
return spec;
}
项目:recycler-fast-scroll
文件:CustomHandleBehavior.java
protected HandleAnimationManager(View handle, @AnimatorRes int grabAnimator, @AnimatorRes int releaseAnimator) {
if (grabAnimator != -1) {
this.grabAnimator = (AnimatorSet) AnimatorInflater.loadAnimator(handle.getContext(), grabAnimator);
this.grabAnimator.setTarget(handle);
}
if (releaseAnimator != -1) {
this.releaseAnimator = (AnimatorSet) AnimatorInflater.loadAnimator(handle.getContext(), releaseAnimator);
this.releaseAnimator.setTarget(handle);
}
}
项目:CookieBar2
文件:CookieBar.java
public Builder setIconAnimation(@AnimatorRes int iconAnimation) {
params.iconAnimator = (AnimatorSet) AnimatorInflater.loadAnimator(context, iconAnimation);
return this;
}
项目:LoadingLayout
文件:LoadingLayout.java
public void setLoadingAnim(@AnimatorRes int animId) {
mLoadingAnim = AnimatorInflater.loadAnimator(getContext(), animId);
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
*/
@Override
@AnimatorRes
public int getIncomingAnimation() {
return mInAnimRes;
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
*/
@Override
@AnimatorRes
public int getOutgoingAnimation() {
return mOutAnimRes;
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
*/
@Override
@AnimatorRes
public int getIncomingBackStackAnimation() {
return mInBackAnimRes;
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
*/
@Override
@AnimatorRes
public int getOutgoingBackStackAnimation() {
return mOutBackAnimRes;
}
项目:material-components-android
文件:ChipDrawable.java
public void setShowMotionSpecResource(@AnimatorRes int id) {
setShowMotionSpec(MotionSpec.createFromResource(context, id));
}
项目:material-components-android
文件:ChipDrawable.java
public void setHideMotionSpecResource(@AnimatorRes int id) {
setHideMotionSpec(MotionSpec.createFromResource(context, id));
}
项目:material-components-android
文件:Chip.java
public void setShowMotionSpecResource(@AnimatorRes int id) {
if (chipDrawable != null) {
chipDrawable.setShowMotionSpecResource(id);
}
}
项目:material-components-android
文件:Chip.java
public void setHideMotionSpecResource(@AnimatorRes int id) {
if (chipDrawable != null) {
chipDrawable.setHideMotionSpecResource(id);
}
}
项目:AndroidAssist
文件:ActivityManager.java
@AnimatorRes public int getInAnimationId() {
return in;
}
项目:AndroidAssist
文件:ActivityManager.java
@AnimatorRes public int getOutAnimationId() {
return out;
}
项目:recycler-fast-scroll
文件:CustomHandleBehavior.java
public Builder withGrabAnimator(@AnimatorRes int grabAnimator) {
this.grabAnimator = grabAnimator;
return this;
}
项目:recycler-fast-scroll
文件:CustomHandleBehavior.java
public Builder withReleaseAnimator(@AnimatorRes int releaseAnimator) {
this.releaseAnimator = releaseAnimator;
return this;
}
项目:recycler-fast-scroll
文件:VisibilityAnimationManager.java
public AbsBuilder<T> withShowAnimator(@AnimatorRes int showAnimatorResource){
this.showAnimatorResource = showAnimatorResource;
return this;
}
项目:recycler-fast-scroll
文件:VisibilityAnimationManager.java
public AbsBuilder<T> withHideAnimator(@AnimatorRes int hideAnimatorResource){
this.hideAnimatorResource = hideAnimatorResource;
return this;
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
* Creates a new instance of BasicFragmentTransition with the specified animations and name.
*
* @param inAnim A resource id of the animation for an incoming fragment.
* @param outAnim A resource id of the animation for an outgoing fragment to be added to the
* back stack or to be destroyed and replaced by the incoming one.
* @param inBackAnim A resource id of the animation for an incoming fragment to be showed from
* the back stack.
* @param outBackAnim A resource id of the animation for an outgoing fragment to be destroyed and
* replaced by the incoming one.
* @param name Name for the new transition.
*/
public BasicFragmentTransition(@AnimatorRes final int inAnim, @AnimatorRes final int outAnim, @AnimatorRes final int inBackAnim, @AnimatorRes final int outBackAnim, @NonNull final String name) {
this.mInAnimRes = inAnim;
this.mOutAnimRes = outAnim;
this.mInBackAnimRes = inBackAnim;
this.mOutBackAnimRes = outBackAnim;
this.mName = name;
}
项目:XinFramework
文件:ExtraTransaction.java
/**
* Set specific animation resources to run for the fragments that are
* entering and exiting in this transaction. These animations will not be
* played when popping the back stack.
*/
public abstract ExtraTransaction setCustomAnimations(@AnimatorRes @AnimRes int targetFragmentEnter,
@AnimatorRes @AnimRes int currentFragmentPopExit);
项目:XinFramework
文件:ExtraTransaction.java
/**
* Set specific animation resources to run for the fragments that are
* entering and exiting in this transaction. The <code>currentFragmentPopEnter</code>
* and <code>targetFragmentExit</code> animations will be played for targetFragmentEnter/currentFragmentPopExit
* operations specifically when popping the back stack.
*/
public abstract ExtraTransaction setCustomAnimations(@AnimatorRes @AnimRes int targetFragmentEnter,
@AnimatorRes @AnimRes int currentFragmentPopExit,
@AnimatorRes @AnimRes int currentFragmentPopEnter,
@AnimatorRes @AnimRes int targetFragmentExit);
项目:android_fragments
文件:BasicFragmentTransition.java
/**
* Same as {@link #BasicFragmentTransition(int, int, int, int)} with back-stack animations set
* to {@link #NO_ANIMATION}.
*/
public BasicFragmentTransition(@AnimatorRes final int inAnim, @AnimatorRes final int outAnim) {
this(inAnim, outAnim, NO_ANIMATION, NO_ANIMATION);
}
项目:android_fragments
文件:BasicFragmentTransition.java
/**
* Same as {@link #BasicFragmentTransition(int, int, int, int, String)} with name specified
* as {@code "UNSPECIFIED"}.
*/
public BasicFragmentTransition(@AnimatorRes final int inAnim, @AnimatorRes final int outAnim, @AnimatorRes final int inBackAnim, @AnimatorRes final int outBackAnim) {
this(inAnim, outAnim, inBackAnim, outBackAnim, "UNSPECIFIED");
}
项目:android_fragments
文件:FragmentTransition.java
/**
* Returns the animation resource for a new incoming fragment.
*
* @return Animation resource or {@link #NO_ANIMATION} if no animation should be played for
* incoming fragment.
*/
@AnimatorRes
int getIncomingAnimation();
项目:android_fragments
文件:FragmentTransition.java
/**
* Returns the animation resource for the current outgoing fragment.
*
* @return Animation resource or {@link #NO_ANIMATION} if no animation should be played for
* outgoing fragment.
*/
@AnimatorRes
int getOutgoingAnimation();