I'm trying to build a view that will have standard tabs on the bottom and action bar tabs in the upper part of the screen.
I've tried using FragmentTabHost
together with TabLayout
but with no success since they both call getSupportFragmentManager()
so one cancels another.
I've also thought about using deprecated TabLayoutActivity
but I'm using AppCompat theme so all my activities have to inherit AppCompatActivity
.
Is there a way for bottom tab to start activities and upper one fragments, or at least both starting fragments that work?
You can have 2 framelayouts (bottom,middle).
On bottom framelayout you will have a fragment with buttons as tabs, when you click on each button you will send back to activity which button clicked.
On middle framelayout you can have a TabLayout fragment and if you prefer also 1 fragment for each tab in the tablayout.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With