Android AccelerateInterpolator - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Android AccelerateInterpolator class.

This code example shows how to use the following methods:
This code example shows how to use the following methods:
    private CharSequence mPullRefreshLabel, mRefreshingLabel, mReleaseLabel;
 
    private boolean mUseCustomProgressColor = false;
    private int mProgressDrawableColor;
 
    private final Interpolator mInterpolator = new AccelerateInterpolator();
 
    protected DefaultHeaderTransformer() { 
        final int min = getMinimumApiLevel();
        if (Build.VERSION.SDK_INT < min) {
            throw new IllegalStateException("This HeaderTransformer is designed to run on SDK "
                    + min
                    + "+. If using ActionBarSherlock or ActionBarCompat you should use the appropriate provided extra."); 
        } 
    } 
 
    @Override 
    public void onViewCreated(Activity activity, View headerView) {
        // Get ProgressBar and TextView. Also set initial text on TextView 
        mHeaderProgressBar = (ProgressBar) headerView.findViewById(R.id.ptr_progress);
7
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
        // The animation listener is used to trigger the next animation 
        final Rotate3dAnimation rotation =
                new Rotate3dAnimation(start, end, centerX, centerY, 310.0f, true);
        rotation.setDuration(500);
        rotation.setFillAfter(true);
        rotation.setInterpolator(new AccelerateInterpolator());
        rotation.setAnimationListener(new DisplayNextView(position));
 
        mContainer.startAnimation(rotation);
    } 
 
    public void onItemClick(AdapterView<?> parent, View v, int position, long id) {
        // Pre-load the image then start the animation 
        mImageView.setImageResource(PHOTOS_RESOURCES[position]);
        applyRotation(position, 0, 90);
    } 
 
    public void onClick(View v) {
        applyRotation(-1, 180, 90); 
    } 
7
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
            return mInternal.getInterpolation(Math.min(mFactor * input, 1f)); 
        } 
    }; 
 
    Interpolator mSlowFadeInterpolator = new Interpolator() {
        Interpolator mInternal = new AccelerateInterpolator(1.5f); 
        float mFactor = 1.3f; 
        @Override 
        public float getInterpolation(float input) { 
            input -= (1 - 1 / mFactor); 
            input = mFactor * Math.max(input, 0f); 
            return mInternal.getInterpolation(input); 
        } 
    }; 
 
    void animatePagesToCarousel() { 
        if (mChildrenTransformsAnimator != null) {
            mChildrenTransformsAnimator.cancel();
            mChildrenTransformsAnimator = null;
        } 
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
                                  getHeight());
      anim.setAnimationListener(collapseListener);
    } 
     
    anim.setDuration(speed);
    anim.setInterpolator(new AccelerateInterpolator(1.0f));
    startAnimation(anim);
  } 
   
  Animation.AnimationListener collapseListener=new Animation.AnimationListener() {
    public void onAnimationEnd(Animation animation) { 
      setVisibility(View.INVISIBLE); 
    } 
     
    public void onAnimationRepeat(Animation animation) { 
      // not needed 
    } 
     
    public void onAnimationStart(Animation animation) { 
      // not needed 
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
		fadeIn = new AlphaAnimation(0, 1);
		fadeIn.setInterpolator(new DecelerateInterpolator());
		fadeIn.setDuration(200);
 
		fadeOut = new AlphaAnimation(1, 0);
		fadeOut.setInterpolator(new AccelerateInterpolator());
		fadeOut.setDuration(200);
		 
		isShown = false;
		 
		if (this.target != null) {
			applyTo(this.target);
		} else { 
			show(); 
		} 
		 
	} 
 
	private void applyTo(View target) {
		 
7
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
      set.addAnimation(fadeOut);
    } 
     
    set.addAnimation(anim);
    set.setDuration(speed);
    set.setInterpolator(new AccelerateInterpolator(1.0f));
    startAnimation(set);
  } 
   
  Animation.AnimationListener collapseListener=new Animation.AnimationListener() {
    public void onAnimationEnd(Animation animation) { 
      setVisibility(View.INVISIBLE); 
    } 
     
    public void onAnimationRepeat(Animation animation) { 
      // not needed 
    } 
     
    public void onAnimationStart(Animation animation) { 
      // not needed 
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
This code example shows how to use the following methods:
	private CharSequence mPullRefreshLabel, mRefreshingLabel, mReleaseLabel;
 
	private boolean mUseCustomProgressColor = false;
	private int mProgressDrawableColor;
 
	private final Interpolator mInterpolator = new AccelerateInterpolator();
 
	protected DefaultHeaderTransformer() { 
		final int min = getMinimumApiLevel();
		if (Build.VERSION.SDK_INT < min)
			throw new IllegalStateException("This HeaderTransformer is designed to run on SDK " + min
					+ "+. If using ActionBarSherlock or ActionBarCompat you should use the appropriate provided extra."); 
	} 
 
	@Override 
	public void onPulled(final float percentagePulled) {
		if (mHeaderProgressBar != null) {
			mHeaderProgressBar.setVisibility(View.VISIBLE);
			final float progress = mInterpolator.getInterpolation(percentagePulled);
			mHeaderProgressBar.setProgress(Math.round(mHeaderProgressBar.getMax() * progress));
6
CodeRank
Experience pair programming with AI  Get Codota for Java
This code example shows how to use the following methods:
 
        private void createAnimation() { 
            if (bounceAnim == null) {
                bounceAnim = ObjectAnimator.ofFloat(ball, "y", ball.getY(), getHeight() - 50f).
                        setDuration(1500); 
                bounceAnim.setInterpolator(new AccelerateInterpolator(2f));
                bounceAnim.addUpdateListener(this);
            } 
        } 
 
        public void startAnimation() { 
            createAnimation(); 
            bounceAnim.start();
        } 
 
        public void reverseAnimation() { 
            createAnimation(); 
            bounceAnim.reverse();
        } 
 
6
CodeRank
Experience pair programming with AI  Get Codota for Java

Related Android AccelerateInterpolator Questions & Answers:

See Code Examples for Android AccelerateInterpolator Methods: