I've read around that nesting Fragments should be avoided (eg. here), but I can't see how to do the following:
I'm working on a tab application (android:minSdkVersion="12"
) with the following UI:
The search bar is always here and the user can navigate through several menu options ('home', 'gallery'...). My idea was to use a BaseActivity with a layout containing the search bar and a FrameLayout in which I would load the Fragment corresponding to the user navigation choice.
My issue is that in the 'Home' Fragment I have several tabs, which I wanted to implement the same way, i.e. with a layout containing the tab bar and a FrameLayout in which I would load the corresponding Fragment, and this leads to nested Fragment...
I know that instead of the BaseActivity I could use several activities and include the search bar in every layout, but it would make it appear and disappear every time the user would change activities...
EDIT
I also need a fixed footer, so I cannot use action bar as proposed by CommonsWare in his answer.
Anybody could help?