I have a basic action with a navigation box, and I'm trying to implement a tabbed play app like Play Music App.
MainActivity has FrameLayout as a container:
<FrameLayout android:id="@+id/container" android:layout_width="match_parent" android:layout_height="match_parent" />
and I want to place a Tab Fragment inside @ + id / container.
What is the best way to do this?
I thought I could create a MyFragment that extends the fragment and implements the TabListener. The corresponding layout may look like
<?xml version="1.0" encoding="utf-8"?> <android.support.v4.view.ViewPager xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/pager" android:layout_width="match_parent" android:layout_height="match_parent" > </android.support.v4.view.ViewPager>
But how can I continue?
source share