I've extended the LinearLayout class into a subclass that inflates the resource xml and holds some custom button logic. According to Building Custom Components I now can use it in place of Linear Layout. Question is: How do I use this class to set my view in my activity? I've tried using in the main.xml but that didn't work. Thanks!