title: SurfaceView crashing - Why?
body: <p>Right now i'm trying to test SurfaceView. It shows up in my Preview. It shows a gray background with the name of my custom SurfaceView ('RollView'). Each time i try to test it. It just crashes immediately. When i remove the com.hovanky.roll.RollView xml tag, it works. But i lose my surfaceview.  What am i doing wrong?</p>
  
  <p>In xml I put in my custom SurfaceView</p>
  
  <pre><code>&lt;FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
           android:layout_width="match_parent"
           android:layout_height="match_parent"&gt;
  
  
  &lt;com.hovanky.roll.RollView
          android:id="@+id/rollview"
          android:layout_width="match_parent"
          android:layout_height="match_parent"/&gt;
  
  
  &lt;RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
              android:orientation="vertical"
              android:layout_width="match_parent"
              android:layout_height="match_parent"&gt;
  
  &lt;/RelativeLayout&gt;
  &lt;/FrameLayout&gt;
  </code></pre>
  
  <p>In my activity, that extends activity. I give handles to my SurfaceView</p>
  
  <pre><code> @Override
   public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.main);
  
      mRollView = (RollView) findViewById(R.id.rollview);
  </code></pre>
  
  <p>Then, I draw up a skeleton of my custom SurfaceView. </p>
  
  <pre><code> class RollView extends SurfaceView implements SurfaceHolder.Callback {
   private SurfaceHolder holder;
  
   public RollView(Context context) {
      super(context);
      holder= getHolder();
      holder.addCallback(this);
  }
  
  
  @Override
  public void surfaceCreated(SurfaceHolder holder) {
  }
  
  @Override
  public void surfaceChanged(SurfaceHolder holder, int format, int width, int height) {
  }
  
  @Override
  public void surfaceDestroyed(SurfaceHolder holder) {
  }
  </code></pre>