title: How can I draw an animated view in android?
body: <p>I created a custom view from scratch. Extended <code>View</code> and overrided <code>onDraw()</code>.
  When comes down in animating the view i generate a custom animation using offsets.
  eg. </p>
  
  <pre><code>while(!isOnTop){
  mOffset++;
  
  //draw the component a a it higher using the offset
  
  if(position == 0)
  isOnTop==true;
  invalidate();
  
  }
  </code></pre>
  
  <p>The thinking is that my frames come from invalidate it self. The problem is that invalidation of this view can come just by scrolling a listview at the same screen.</p>
  
  <p>This "shared invalidation()" causes lag to my animation.So is there a way out of that lag? </p>
  
  <p>Do you have any other suggestion of performing animations in that shared enviroment?
  Creating an animation using a seperate thread that calculates the offset also needs forced invalidation() calls to display the animation (correct me if i'm wrong).</p>
  
  <p>Is the only solution to perform the animation in eg 10 invalidation requests with a larger step? It will ease the lag out but i think i can use a different approach on that.</p>