I'm implementing navigation using list navigation mode.
Currenly i'm have 3 absolutely different and unrelated listviews which can be switched by tapping needed item from navigation menu spinner.
Those listviews is implemented as fragments which is switched by fragmentManager.replace()
every time when user picks item from navigation menu.
It works now and all was perfect... Until i want normal multiscreen device support.
As i understand the key point for multiscreen support is having separate layouts for different screen sizes. But in this case i can't use this layout in fragment because i will need to nest fragments into fragment container. But nested fragments wasn't supported for a time ago.
To make it more clear, please, look at the schema below
MainActivity -> FragmentA -> ListView
-> FragmentB -> ListView
-> FragmentC -> ListView
If i make FragmentA container with layout depending on screen size then i need to nest original FragmentA into this container, i.e.:
for tablet:
MainActivity -> FragmentContainer (also Fragment) -> FragmentA
-> DetailsFragment
for phone:
MainActivity -> FragmentContainer -> FragmentA
Should i wrap all existing fragment into separate activities and switch between those activities instead? Or i should use fresh Android Support library with nested fragments support?
What do u think?
Thanks for any help.
Similar question: Fragment Tabs and Fragment Activities