title: Android Custom Component doesn't show anything after inflate
body: <p>Trying to create a custom component that gets it's layout from an XML file (box.xml).  I have gone through a couple of tutorials but just can't seem to get anything to display. Below is the constructors for my custom component and the code does get executed without errors.</p>
  
  <pre><code>public class MyView extends LinearLayout {
      //Constructor required for inflation from resource file
      public MyView(Context context, AttributeSet attrs) {
          super(context, attrs);        
          LayoutInflater layoutInflater = (LayoutInflater)context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
          View view=layoutInflater.inflate (R.layout.box, this);                        
          Log.d("CONSTRUCTOR 2", "TESTER");        
      }
  }
  </code></pre>
  
  <p>I add the component to a layout with this:</p>
  
  <pre><code>&lt;com.mysample.MyView android:layout_width="50dp" android:layout_height="38dp" android:background="#FF000000" /&gt;
  </code></pre>
  
  <p>The black block does appear on the screen but not with the layout of the xml file I inflate it with.</p>