Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I tried to create the animation described in your drawing. I split the animation in 2 files left_down.xml</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;set xmlns:android="http://schemas.android.com/apk/res/android" android:interpolator="@android:anim/linear_interpolator" android:shareInterpolator="true"&gt; &lt;set&gt; &lt;translate android:fromXDelta="0%p" android:toXDelta="-80%p" android:fromYDelta="00%p" android:toYDelta="0%p" android:duration="2000" android:startOffset="0"/&gt; &lt;translate android:fromXDelta="0%p" android:toXDelta="0%p" android:fromYDelta="00%p" android:toYDelta="20%p" android:duration="2000" android:startOffset="2000"/&gt; &lt;/set&gt; &lt;/set&gt; </code></pre> <p>right.xml</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;translate xmlns:android="http://schemas.android.com/apk/res/android" android:fromXDelta="-80%p" android:toXDelta="0%p" android:fromYDelta="20%p" android:toYDelta="20%p" android:duration="2000" android:fillAfter="true"/&gt; </code></pre> <p>And this is the code I used in the activity</p> <pre><code>image = (ImageView)findViewById(R.id.image); anim = AnimationUtils.loadAnimation(this, R.anim.left_down); goBack = AnimationUtils.loadAnimation(this, R.anim.right); anim.setAnimationListener(new AnimationListener() { @Override public void onAnimationStart(Animation animation) {} @Override public void onAnimationRepeat(Animation animation) {} @Override public void onAnimationEnd(Animation animation) { image.startAnimation(goBack); } }); image.startAnimation(anim); </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload