title: TextSwitcher NullPointer errors
body: <p>I am really stuck on this.  I am trying to do a simple textswitcher which will increment a quantity and update a price based on the quantity.  Right now in my xml i have something like a TextView within a TextSwitcher just to increment the quantity.  I get the textview with <code>findViewById(R.id.quantity)</code>. </p>
  
  <p>so this is what i have to find to setup the increment quantity ( I am implemementing ViewFactory)</p>
  
  <pre><code>switcher = (TextSwitcher) findViewById(R.id.switcher);
  switcher.setFactory(this);
  quantity = (TextView) findViewById(R.id.quantity);
  </code></pre>
  
  <p>I am also overriding the makeView()</p>
  
  <pre><code>@Override
       public View makeView() {
          return quantity;
      }
  </code></pre>
  
  <p>Also when an increment button is pressed i increment the counter and set the text on the switcher to the current count.  Like this:</p>
  
  <pre><code>switcher.setText(String.valueOf(currentQuantity));
  </code></pre>
  
  <p>Can someone let me know what I am doing wrong??  I keep getting my nullpointer at this line:</p>
  
  <pre><code>switcher.setFactory(this);
  </code></pre>
  
  <p>Here is the XML snippet:</p>
  
  <pre><code>&lt;TextSwitcher android:layout_width="match_parent" android:layout_height="wrap_content" android:id="@+id/switcher"&gt;
              &lt;TextView android:text="TextView" android:id="@+id/quantity" android:layout_width="wrap_content" android:layout_height="wrap_content"&gt;&lt;/TextView&gt;
          &lt;/TextSwitcher&gt;
  </code></pre>