2

I'm using an android sherlock action bar with 5 tabs. I would like to start that app showing the 5 tabs but without any selected tab (I know it could be confusing for the end user...) Is it possible ? How to do that ?

fvisticot
  • 7,936
  • 14
  • 49
  • 79
  • even if you try to make no tabs selected, tabs have property of setting default tab selected to the tab of zeroth index – Abhinav Singh Maurya Feb 26 '13 at 12:34
  • Yep, agree...without selecting a specific tab, tab0 is selected by default...and it is my pb :) how to avoid this "default mechanism" ? is it possible ? – fvisticot Feb 26 '13 at 12:36
  • Well In my view its not possible but keep trying to get answer may be someone answer to this. I am also waiting for the answer – Abhinav Singh Maurya Feb 26 '13 at 12:39
  • I would revise the UI to not do this. That's akin to saying "I want a browser that has a bunch of tabs, but the user cannot see any Web pages". – CommonsWare Feb 26 '13 at 15:09

1 Answers1

1

I have no idea why you want to create something like this but maybe 1 hacky solution...

Create a custom tab that replaces the selected tab drawable image with the unselected tab drawable image. When you click a tab after that it replaces the theme back to the default tab selected.

Edit: I found a post explaining this "trick" further.

'Unselect' a tab in a TabHost

Community
  • 1
  • 1
Edward van Raak
  • 4,841
  • 3
  • 24
  • 38