[android-developers] Re: ViewGroup parent for merge

2009-06-23 Thread az9702
Right. In this case, neither LinearLayout or merge is needed. Thanks for your help. On Jun 23, 8:13 am, Josh Guilfoyle wrote: > This is not a case where is necessary.  If you have only 1 > widget ultimately, icon_row or icon_text, you simply must put that at > the root of the XML.  It is not

[android-developers] Re: ViewGroup parent for merge

2009-06-23 Thread Josh Guilfoyle
This is not a case where is necessary. If you have only 1 widget ultimately, icon_row or icon_text, you simply must put that at the root of the XML. It is not necessary for you to wrap it in a LinearLayout, nor is it necessary for your adapter to work exclusively with a ViewGroup. On Jun 22, 1

[android-developers] Re: ViewGroup parent for merge

2009-06-22 Thread az9702
Josh, I have getViewTypeCount (2 here) & getItemViewType (0/text_row, 1/ icon_row) in my adapter so it knows about the two row types. ConvertView is set to the correct row type. The question is how correctly apply merge & remove LinearLayout given: * layout/icon_row.xml w/ /icon_row * layout/i

[android-developers] Re: ViewGroup parent for merge

2009-06-22 Thread simon.y.sz...@gmail.com
Josh, I have getViewTypeCount (2 here) & getItemViewType (0/text_row, 1/ icon_row) in my adapter so it knows about the two row types. ConvertView is set to the correct row type. The question is how to correctly apply merge to rid of the LinearLayout in: * layout/icon_row.xml w/ /icon_row * lay

[android-developers] Re: ViewGroup parent for merge

2009-06-22 Thread Josh Guilfoyle
You definitely don't want to access the list directly from the adapter. Instead for your design what you'd want to do is remove the outer linear layout if you can and just have two separate XML files with only 1 view each (text_row or icon_row). Then in your adapter override the methods getItemV