Is there any help, resources, example or a tutorial available for putting fragments inside a fragment?
I have two tabs put up using Action Bar Navigation tabs, which essentially are fragments. What I want to do is, put in a ListFragment and a DialogFragment (to display a view with details) in one of those Action Bar Navigation tabs fragment.
Possible?? Please help. Thanks
Here's what I have done till now:
- Followed Android's article on implementing navigation tabs on Action Bar and implemented a two tab action bar, this is running fine and I am able to show two different layouts.
- In one of these tabs, I want to show a Fragmented view, for this I have created a FragmentList class with custom ArrayAdapter and data items, the data detail layout and class.
- I am now stuck on how to display the fragments inside the tab. Following is the code which shows the content of first tab, how can I modify it to initialize the list fragment properly?
.
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
{
View viewer = (View) inflater.inflate(R.layout.doodle_list, container,false);
return viewer;
}