Created
January 31, 2012 03:31
-
-
Save nitindhar7/1708580 to your computer and use it in GitHub Desktop.
Fragment - adding another tab (repeatitive)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add another tab | |
tab = inflater.inflate(R.layout.tab, getTabWidget(), false); | |
tab.setLayoutParams(params); | |
label = (TextView) tab.findViewById(R.id.tabLabel); | |
label.setText("USERS"); | |
intent = new Intent(TabTutorialActivity.this, TabContentActivity.class); | |
intent.putExtra("content", "Content for USERS"); | |
spec = tabHost.newTabSpec("users").setIndicator(tab).setContent(intent); | |
tabHost.addTab(spec); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment