ViewFlipper crashes after orientation change
<p>I'm trying to use inflate while using ViewFlipper to access to the data inside my view. I've done sample project that crashes.</p>

<p><code>main.xml</code><br>
        &lt; ?xml version="1.0" encoding="utf-8"?><br>
        &lt; ViewFlipper<br>
    xmlns:android="http://schemas.android.com/apk/res/android"<br>
    android:id="@+id/RelativeLayout"<br>
    android:layout_width="wrap_content"<br>
    android:layout_height="wrap_content" /></p>

<p><code>FlipViewBug.java</code>  </p>

<pre><code>package android.FlipViewBug;
import android.app.Activity;
import android.content.Context;
import android.os.Bundle;
import android.view.LayoutInflater;
public class FlipViewBug extends Activity {
    private static LayoutInflater inflater = null;
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        inflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE);
    }
}
</code></pre>

<p>When I rotate emulator from horizontal to vertical orientation (CTRL+F11) app crashes with "stopped unexpectedly". If I remove line<br>
inflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE);<br>
app works 'fine'. Am I trying to do something wrong? In my app I have more complex LinnarView that ViewFlipper is nested and the results are the same.<br>
I was checking this on android 1.5, 2.2 and galaxy tab. There is no problem while rotating form vertical view to horizontal.</p>
