开发者

First tab automatically starts in the background in the tabHost in android

I noticed a peculiar problem in my Android app.

Actually, in my app I am using TabHost and setting the current tab dynamically in runtime using setCurrentTab(i) where the value of i is coming from some other previous Activity.

Now the problem is that whatever I set the value of i, i.e. the current tab, the first tab activity ( onCreate() method) always starts in background and as I am using the progressBar in only first tab Activity, I can notice that progress bar in other tab开发者_StackOverflow中文版GroupActivity also. And also as I am parsing some data in First tabActivity, that is also executed in the background and hence consuming unnecessary memory.

Any idea or help will be highly appreciated.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜