2
votes

I am newbie with fragments and actionbar in android. I want to develop application for tablets which has multiple tabs, each tab has Listview in the leftside and the details of the item on the right side

Here is an example of what i want to do.

I don't know which of this is activity and which is a fragment and how to navigate using this tabs and change the content of the listview and the details.

I want examples to navigate using tabs with multipane layout because I searched about that and I found tabs are using fragments and multipane is composed of two fragments and nested fragments not allowed in android.

And I want to know: What is the difference between activity and fragmentActivity?

1
Did you get the solution? Pls I also wanted to do like this. Still couldn't - Piraba
No , i didn't find a solution yet - Ebtehal___

1 Answers

0
votes

Fragment Tutorials

Google "android fragment tutorial" and you'll get a lot of results like this: http://www.vogella.com/articles/AndroidFragments/article.html

Don't stick with only one though because many of them vary just slightly and if you do two or three then you'll have a better understanding of how fragments work (standalone or multipane).

Fragments with Tabs

A great way to see an example of switching fragments is by creating a new android project in Eclipse using the latest ADT. Create a new Android Application Project and when you're setting the name of the main activity you have an option to set the navigation type. Choose tabs or tabs+swipe. This will generate a clean project for you to see the very basics of how to switch fragments using tabs.

Activity vs FragmentActivity Essentially, an Activity may contain a layout with no fragments and a FragmentActivity may contain a layout with fragments. This answer has a few more details: Difference between Activity and FragmentActivity