title: my viewPager tabs doesn't show
body: <p>hello i have a problem in my material test application , i want to test the tab design but it didnt work for me , im following a tutorial and i did the same , but it didnt work , all fragment and xml files are good just this is not working 
  can someone help me ! 
  thanks   </p>
  
  <pre><code>private ViewPager mPager;
  private SlidingTabLayout mTab;
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
  
      toolbar = (Toolbar) findViewById(R.id.app_bar);
      setSupportActionBar(toolbar);
      getSupportActionBar().setDisplayShowHomeEnabled(true);
      NavigationDrawerFragment drawerFragment = (NavigationDrawerFragment)
              getSupportFragmentManager().findFragmentById(R.id.fragment_navigation_drawer);
      drawerFragment.setUp(R.id.fragment_navigation_drawer, (DrawerLayout) findViewById(R.id.drawerLayout), toolbar);
  
      mPager = (ViewPager) findViewById(R.id.pager);
      mPager.setAdapter(new MyPagerAdapter(getSupportFragmentManager()));
      mTab = (SlidingTabLayout) findViewById(R.id.tabs);
      mTab.setViewPager(mPager);
  
  
  }
  
  class MyPagerAdapter extends FragmentPagerAdapter {
  
      String[] tabs;
  
      public MyPagerAdapter(FragmentManager fm) {
          super(fm);
          tabs = getResources().getStringArray(R.array.tabs);
      }
  
      @Override
      public Fragment getItem(int position) {
          MyFragment myFragment = MyFragment.getInstance(position);
  
          return myFragment;
      }
  
      @Override
      public CharSequence getPageTitle(int position) {
          return tabs[position];
      }
  
      @Override
      public int getCount() {
          return 3;
      }
  }
  
  public static class MyFragment extends Fragment {
      private TextView textView;
  
      public static MyFragment getInstance(int position) {
          MyFragment myFragment = new MyFragment();
          Bundle args = new Bundle();
          args.putInt("position", position);
          myFragment.setArguments(args);
          return myFragment;
      }
  
  
      @Nullable
      @Override
      public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
          View layout = inflater.inflate(R.layout.frament_my, container, false);
          textView = (TextView) layout.findViewById(R.id.position);
          Bundle bundle = getArguments();
  
          if (bundle != null) {
              textView.setText("The page selector is " + bundle.getInt("position") + 1);
          }
  
          return layout;
      }
  }
  </code></pre>
  
  <p>}</p>