title: Creating login animation like facebook android
body: <p>I want to create a login page (Like facebook android app) where the userid and password <code>EditText</code> fields are hidden. A logo is shown on the page which animates above upto a certain distance and stays at the new position and then the edit fields are shown. </p>
  
  <p>Here is something I have tried. But here the logo starts from bottom of the page and travels to the top of the page. Where as I want the logo to start from middle of the page and shift a little up to its new position. </p>
  
  <p>Any idea on how this can be done>?</p>
  
  <p>main.xml</p>
  
  <pre><code>  &lt;ImageView
          android:id="@+id/imageView1"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:layout_alignParentTop="true"
          android:layout_centerHorizontal="true"
          android:layout_marginTop="116dp"
          android:src="@drawable/ic_launcher" /&gt;
  </code></pre>
  
  <p>res/anim/animationfile.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" &gt;
  
  &lt;translate
      android:duration="5000"
      android:fromYDelta="50%p"
      android:toYDelta="-50%p" 
     /&gt;
       &lt;/set&gt;
  </code></pre>
  
  <p>Main.java</p>
  
  <pre><code>  Animation translatebu= AnimationUtils.loadAnimation(this, R.anim.animationfile);
         // tv.setText("Some text view.");
          img.startAnimation(translatebu);
  </code></pre>
  
  <hr>