Hybris wrote: > On 22 Giu, 23:28, Mark Murphy <[email protected]> wrote: > >> setContent() takes an ID of a widget in the tab host's own layout, not >> another layout. >> > > so, what is the way to use a sofisticated layout inside a tab without > having to copy the xml in the tab host xml? > building a coumpound view?
I'm not sure what a "compound view" is, exactly. You can inflate the other layouts yourself and use TabHost.TabContentFactory to return the inflated layout for use in your TabSpec. Or, you can use <include> in the layout with your tabs to inject the contents of other layouts: http://www.curious-creature.org/2009/02/25/android-layout-trick-2-include-to-reuse/ -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Development Wiki: http://wiki.andmob.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~----------~----~----~----~------~----~------~--~---

