How to create the delay of 1 sec before set the alpha of View?
Solution 1:
In your animation xml
file you can use android:startOffset
attribute:
android:startOffset int. The amount of milliseconds the animation delays after start() is called.
Solution 2:
Can't you use the
android:startOffset int. The amount of milliseconds the animation delays after start() is called.
in your animation xml?
See the animation resource documentation.
Solution 3:
Suppose you are using the view .animate()
method, you can set the start offset:
view.animate().x(100)
.setDuration(5000)
.setStartDelay(1000);