title: Using SimonVT number picker and unable to inflate xml
body: <p>So I'm using  <a href="https://github.com/SimonVT/android-numberpicker" rel="nofollow">SimonVT number picker</a> to try and create a number picker that works with gingerbread.  Unfortunately when I try to set it up as a dialog, it crashes when it tries to inflate the xml.  I honestly have spent a while on this and cannot for the love of me figure out.  Can anyone else?</p>
  
  <p>This is where it crashes:</p>
  
  <pre><code>import net.simonvt.numberpicker.NumberPicker;
  import android.app.AlertDialog;
  import android.app.Dialog;
  import android.os.Bundle;
  import android.support.v4.app.DialogFragment;
  import android.view.View;
  
  public class setSnoozeMethodDialog extends DialogFragment{
  
  @Override
  public Dialog onCreateDialog(Bundle savedInstanceState) {
  
      AlertDialog.Builder builder = new AlertDialog.Builder(getActivity());
      View view = getActivity().getLayoutInflater().inflate(R.layout.set_snooze_dialog, null);
  
      NumberPicker np = (NumberPicker) view.findViewById(R.id.numberPicker);
      np.setMaxValue(20);
      np.setMinValue(0);
      np.setFocusable(true);
      np.setFocusableInTouchMode(true);
  
      builder.setView(view);
  
      return builder.create();
  }
  </code></pre>
  
  <p>This is the xml that is having trouble being inflated</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"
  android:gravity="center"&gt;
  
  &lt;net.simonvt.numberpicker.NumberPicker
      android:id="@+id/numberPicker"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content" /&gt;
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>This is the error</p>
  
  <pre><code>01-07 23:44:33.308: E/AndroidRuntime(623): FATAL EXCEPTION: main
  01-07 23:44:33.308: E/AndroidRuntime(623): android.view.InflateException: Binary XML file line #8: Error inflating class net.simonvt.numberpicker.NumberPicker
  01-07 23:44:33.308: E/AndroidRuntime(623):  at android.view.LayoutInflater.createView(LayoutInflater.java:518)
  01-07 23:44:33.308: E/AndroidRuntime(623):  at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:570)
  01-07 23:44:33.308: E/AndroidRuntime(623):  at android.view.LayoutInflater.rInflate(LayoutInflater.java:623)
  01-07 23:44:33.308: E/AndroidRuntime(623):  at android.view.LayoutInflater.inflate(LayoutInflater.java:408)
  01-07 23:44:33.308: E/AndroidRuntime(623):  at android.view.LayoutInflater.inflate(LayoutInflater.java:320)
  01-07 23:44:33.308: E/AndroidRuntime(623):  at     android.view.LayoutInflater.inflate(LayoutInflater.java:276)
  </code></pre>
  
  <p>I put these in my manifest already</p>
  
  <pre><code>        &lt;activity
          android:name="net.simonvt.numberpicker.samples.DarkThemeActivity"
          android:theme="@style/SampleTheme" /&gt;
          &lt;activity
          android:name="net.simonvt.numberpicker.samples.LightThemeActivity"
          android:theme="@style/SampleTheme.Light" /&gt;
  </code></pre>
  
  <p>This is in my theme.xml in value folder</p>
  
  <pre><code>&lt;resources&gt;
  
  &lt;style name="SampleTheme" parent="android:Theme"&gt;
      &lt;item name="numberPickerStyle"&gt;@style/NPWidget.Holo.NumberPicker&lt;/item&gt;
  &lt;/style&gt;
  
  &lt;style name="SampleTheme.Light" parent="android:Theme.Light"&gt;
      &lt;item name="numberPickerStyle"&gt;@style/NPWidget.Holo.Light.NumberPicker&lt;/item&gt;
  &lt;/style&gt;
  </code></pre>
  
  <p></p>