I am facing problem in designing following scenario :
Here, I decided to use ActionBar
and to change the view by using fragments to be called from onTabSelected()
of TabListener
; in which I was confused as I have to keep only single activity but multiple fragments. 'Keeping single activity' is this a standard / valid approach ? Please suggest.
Thanks in advance.
I know this is late, but I used a tabhost with fragments to do something similar. Here's a nice tutorial. http://thepseudocoder.wordpress.com/2011/10/04/android-tabs-the-fragment-way/
您应该有一个Activity,并有一个容器(可以是一个空的LinearLayout),其中根据所选的选项卡替换了片段。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.