user2721289
user2721289

Reputation:

animation starting at specific time

I want to use animation in my app, but it shoudn't start from beggining, but from time that I set, hot to achieve that? My code working from beggining of animation:

ImageView someImage = (ImageView) findViewById(R.id.someImage);
Animation someAnimation = AnimationUtils.loadAnimation(this, R.anim.someAnimation);
someImage.startAnimation(someAnimation);

Upvotes: 1

Views: 100

Answers (1)

akuzma
akuzma

Reputation: 1554

You can set time using Animation.setStartTime(), then assign the animation to the View with View.setAnimation().

Check developer.android site: http://developer.android.com/guide/topics/graphics/view-animation.html

Upvotes: 1

Related Questions