android - Tabs as views or Activity? -
i'm developing app requires nested tabs (tabs within tabs). example 1 of tabs message tab have 4 tabs- inbox, compose, sent, trash. have around 3-4 of such nested tabs in app. i'm looking few suggestions whether make these tabs separate activities or views. i've read issue , i'm aware problem specific need of application. beginner i'm skeptical approach. wasn't sure if should have many activities in code hamper performance. of i've created main tabs separate activities , nested tabs views. of inner tabs want user select list of options, though there couple of tabs involve more user interaction. can can achieved activity approach possible via view approach? if so, how? suggestions helpful.
it sounds make nested tabs different options menus each of parent tabs. in each of activities in first tab menu, can add this...
@override public boolean oncreateoptionsmenu(menu menu){ menuinflater inflater = getmenuinflater(); inflater.inflate(r.menu.optionsmenu,menu); return true; }
and implement listener..
@override public boolean onoptionsitemselected(menuitem item) { switch (item.getitemid()) { case r.id.one: case r.id.two: default: } return true; }
i think best way offer more options users each of activities in tab menu. access each 1 of these menus whichever tabactivity
user on. have push default options button.
Comments
Post a Comment