Android with fragments: how to fix issue with inflater in simple application?
<p>I start to learn Fragment paradigm in Android and decide to modify one simple app that used it. My app shows list of items and portrait mode - it works perfectly - and it turned to landscape mode display should show a preceding list and textbox in right side, and here the issue occurs. Excuse me for a lot of code:</p>

<p>main.xml</p>

<pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;fragment 
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:name="home.etudes.News"
    android:id="@+id/list_fragment"
    android:layout_width="match_parent"
    android:layout_height="match_parent" &gt;
&lt;/fragment&gt;
</code></pre>

<p>main.xml in /layout-land</p>

<pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="horizontal"&gt;

    &lt;fragment 
    android:name="home.etudes.News"
    android:id="@+id/list_fragment"
    android:layout_width="match_parent"
    android:layout_height="match_parent" &gt;
&lt;/fragment&gt;

    &lt;fragment 
    android:name="home.etudes.ExtendedNews"
    android:id="@+id/extended_fragment"
    android:layout_width="match_parent"
    android:layout_height="match_parent" &gt;
&lt;/fragment&gt;

&lt;/LinearLayout&gt;
</code></pre>

<p>entry point</p>

<pre><code>public class FrgamentEtudeActivity extends FragmentActivity {

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);
}
</code></pre>

<p>}</p>

<p>list fragment</p>

<pre><code>public class News extends ListFragment {

final String[] array = new String[] {"Article one", "Article two", "Article three"};

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setListAdapter(ArrayAdapter.createFromResource(
            getActivity().getApplicationContext(), 
            R.array.tut_titles, R.layout.list_item));
}
</code></pre>

<p>}</p>

<p>Preceding code works fine until landscape mode has been launched and below code should be invoked (actually it doesn't, I have put break point but app crached in some another part):</p>

<pre><code>public class ExtendedNews extends Fragment {

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
        Bundle savedInstanceState) {
    View view = inflater.inflate(R.layout.list_item, container);
    return view;//textView;
}
</code></pre>

<p>}</p>

<p>If have some thoughts where is issue can be, please share it with me. </p>

<hr>

<p>Here the infromation from logcat:</p>

<p>05-02 17:52:05.345: E/AndroidRuntime(325): FATAL EXCEPTION: main
05-02 17:52:05.345: E/AndroidRuntime(325): <strong>java.lang.RuntimeException: Unable to start activity ComponentInfo{home.etudes/home.etudes.FrgamentEtudeActivity}: android.view.InflateException: Binary XML file line #15: Error inflating class fragment</strong>
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1647)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1663)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.handleRelaunchActivity(ActivityThread.java:2832)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.access$1600(ActivityThread.java:117)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread$H.handleMessage(ActivityThread.java:935)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.os.Handler.dispatchMessage(Handler.java:99)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.os.Looper.loop(Looper.java:123)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.main(ActivityThread.java:3683)
05-02 17:52:05.345: E/AndroidRuntime(325):  at java.lang.reflect.Method.invokeNative(Native Method)
05-02 17:52:05.345: E/AndroidRuntime(325):  at java.lang.reflect.Method.invoke(Method.java:507)
05-02 17:52:05.345: E/AndroidRuntime(325):  at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
05-02 17:52:05.345: E/AndroidRuntime(325):  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
05-02 17:52:05.345: E/AndroidRuntime(325):  at dalvik.system.NativeStart.main(Native Method)
05-02 17:52:05.345: E/AndroidRuntime(325): Caused by: android.view.InflateException: Binary XML file line #15: <strong>Error inflating class fragment
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:587)</strong>
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.rInflate(LayoutInflater.java:623)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.inflate(LayoutInflater.java:408)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.inflate(LayoutInflater.java:276)
05-02 17:52:05.345: E/AndroidRuntime(325):  at com.android.internal.policy.impl.PhoneWindow.setContentView(PhoneWindow.java:207)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.Activity.setContentView(Activity.java:1657)
05-02 17:52:05.345: E/AndroidRuntime(325):  at home.etudes.FrgamentEtudeActivity.onCreate(FrgamentEtudeActivity.java:13)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1611)
05-02 17:52:05.345: E/AndroidRuntime(325):  ... 12 more
05-02 17:52:05.345: E/AndroidRuntime(325): Caused by: android.support.v4.app.Fragment$InstantiationException: <strong>Unable to instantiate fragment home.etudes.ExtendedNews: make sure class name exists, is public, and has an empty constructor that is public</strong>
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.support.v4.app.Fragment.instantiate(Fragment.java:391)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.support.v4.app.Fragment.instantiate(Fragment.java:359)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.support.v4.app.FragmentActivity.onCreateView(FragmentActivity.java:262)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:563)
05-02 17:52:05.345: E/AndroidRuntime(325):  ... 21 more
05-02 17:52:05.345: E/AndroidRuntime(325): Caused by: java.lang.ClassNotFoundException: home.etudes.ExtendedNews in loader dalvik.system.PathClassLoader[/data/app/home.etudes-2.apk]
05-02 17:52:05.345: E/AndroidRuntime(325):  at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:240)
05-02 17:52:05.345: E/AndroidRuntime(325):  at java.lang.ClassLoader.loadClass(ClassLoader.java:551)
05-02 17:52:05.345: E/AndroidRuntime(325):  at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
05-02 17:52:05.345: E/AndroidRuntime(325):  at android.support.v4.app.Fragment.instantiate(Fragment.java:381)</p>
